Last active
November 7, 2023 01:44
-
-
Save agross/614b3c85dcc152e258403f4c5d4273b7 to your computer and use it in GitHub Desktop.
Synology DS2415+ docker 17.05 does not support --build-arg
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM busybox | |
ARG FOO | |
RUN env && echo $FOO |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
agross@firiel ~/Downloads/test | |
$ docker --version | |
Docker version 17.09.0-ce, build afdb6d4 | |
agross@firiel ~/Downloads/test | |
$ docker build --no-cache --build-arg FOO=42 . | |
Sending build context to Docker daemon 2.048kB | |
Step 1/3 : FROM busybox | |
---> 6ad733544a63 | |
Step 2/3 : ARG FOO | |
---> Running in 5905f0697f4e | |
---> 95f0e024daad | |
Removing intermediate container 5905f0697f4e | |
Step 3/3 : RUN env && echo $FOO | |
---> Running in 61b56de4056b | |
HOSTNAME=61b56de4056b | |
SHLVL=1 | |
HOME=/root | |
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin | |
FOO=42 | |
PWD=/ | |
42 | |
---> 22d87fd43a05 | |
Removing intermediate container 61b56de4056b | |
Successfully built 22d87fd43a05 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ docker --version | |
Docker version 17.05.0-ce, build 34ed091-synology | |
agross@NAS ~/test | |
$ docker build --no-cache --build-arg FOO=42 . | |
Sending build context to Docker daemon 2.048kB | |
Step 1/3 : FROM busybox | |
---> 6ad733544a63 | |
Step 2/3 : ARG FOO | |
---> Running in 98bb102c933b | |
---> 85a15904257a | |
Removing intermediate container 98bb102c933b | |
Step 3/3 : RUN env && echo $FOO | |
---> Running in 1b1f68c48247 | |
HOSTNAME=98bb102c933b | |
SHLVL=1 | |
HOME=/root | |
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin | |
PWD=/ | |
---> e961ab1e9c53 | |
Removing intermediate container 1b1f68c48247 | |
Successfully built e961ab1e9c53 |
FROM busybox
ARG FOO
ENV FOO=$FOO
RUN env && echo $FOO
doesn't look nice but works
This is insane! Been banging my head on this for over an hour now!
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
is there a solution?