Skip to content

Commit be42a31

Browse files
committed
Update entrypoints for Node 17
1 parent dc060bd commit be42a31

File tree

9 files changed

+36
-9
lines changed

9 files changed

+36
-9
lines changed

17/alpine3.12/docker-entrypoint.sh

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
#!/bin/sh
22
set -e
33

4-
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ]; then
4+
# Run command with node if the first argument contains a "-" or is not a system command. The last
5+
# part inside the "{}" is a workaround for the following bug in ash/dash:
6+
# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=874264
7+
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ] || { [ -f "${1}" ] && ! [ -x "${1}" ]; }; then
58
set -- node "$@"
69
fi
710

17/alpine3.13/docker-entrypoint.sh

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
#!/bin/sh
22
set -e
33

4-
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ]; then
4+
# Run command with node if the first argument contains a "-" or is not a system command. The last
5+
# part inside the "{}" is a workaround for the following bug in ash/dash:
6+
# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=874264
7+
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ] || { [ -f "${1}" ] && ! [ -x "${1}" ]; }; then
58
set -- node "$@"
69
fi
710

17/alpine3.14/docker-entrypoint.sh

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
#!/bin/sh
22
set -e
33

4-
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ]; then
4+
# Run command with node if the first argument contains a "-" or is not a system command. The last
5+
# part inside the "{}" is a workaround for the following bug in ash/dash:
6+
# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=874264
7+
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ] || { [ -f "${1}" ] && ! [ -x "${1}" ]; }; then
58
set -- node "$@"
69
fi
710

17/bullseye-slim/docker-entrypoint.sh

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
#!/bin/sh
22
set -e
33

4-
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ]; then
4+
# Run command with node if the first argument contains a "-" or is not a system command. The last
5+
# part inside the "{}" is a workaround for the following bug in ash/dash:
6+
# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=874264
7+
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ] || { [ -f "${1}" ] && ! [ -x "${1}" ]; }; then
58
set -- node "$@"
69
fi
710

17/bullseye/docker-entrypoint.sh

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
#!/bin/sh
22
set -e
33

4-
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ]; then
4+
# Run command with node if the first argument contains a "-" or is not a system command. The last
5+
# part inside the "{}" is a workaround for the following bug in ash/dash:
6+
# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=874264
7+
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ] || { [ -f "${1}" ] && ! [ -x "${1}" ]; }; then
58
set -- node "$@"
69
fi
710

17/buster-slim/docker-entrypoint.sh

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
#!/bin/sh
22
set -e
33

4-
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ]; then
4+
# Run command with node if the first argument contains a "-" or is not a system command. The last
5+
# part inside the "{}" is a workaround for the following bug in ash/dash:
6+
# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=874264
7+
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ] || { [ -f "${1}" ] && ! [ -x "${1}" ]; }; then
58
set -- node "$@"
69
fi
710

17/buster/docker-entrypoint.sh

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
#!/bin/sh
22
set -e
33

4-
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ]; then
4+
# Run command with node if the first argument contains a "-" or is not a system command. The last
5+
# part inside the "{}" is a workaround for the following bug in ash/dash:
6+
# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=874264
7+
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ] || { [ -f "${1}" ] && ! [ -x "${1}" ]; }; then
58
set -- node "$@"
69
fi
710

17/stretch-slim/docker-entrypoint.sh

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
#!/bin/sh
22
set -e
33

4-
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ]; then
4+
# Run command with node if the first argument contains a "-" or is not a system command. The last
5+
# part inside the "{}" is a workaround for the following bug in ash/dash:
6+
# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=874264
7+
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ] || { [ -f "${1}" ] && ! [ -x "${1}" ]; }; then
58
set -- node "$@"
69
fi
710

17/stretch/docker-entrypoint.sh

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
#!/bin/sh
22
set -e
33

4-
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ]; then
4+
# Run command with node if the first argument contains a "-" or is not a system command. The last
5+
# part inside the "{}" is a workaround for the following bug in ash/dash:
6+
# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=874264
7+
if [ "${1#-}" != "${1}" ] || [ -z "$(command -v "${1}")" ] || { [ -f "${1}" ] && ! [ -x "${1}" ]; }; then
58
set -- node "$@"
69
fi
710

0 commit comments

Comments
 (0)