VERSION was hardcoded to be used as the `VERSION` file from the root
directory, this makes it so that you have the option to overwrite this.
Signed-off-by: Eli Uriegas <eli.uriegas@docker.com>
... | ... |
@@ -43,7 +43,8 @@ DOCKER_ENVS := \ |
43 | 43 |
-e NO_PROXY \ |
44 | 44 |
-e http_proxy \ |
45 | 45 |
-e https_proxy \ |
46 |
- -e no_proxy |
|
46 |
+ -e no_proxy \ |
|
47 |
+ -e VERSION |
|
47 | 48 |
# note: we _cannot_ add "-e DOCKER_BUILDTAGS" here because even if it's unset in the shell, that would shadow the "ENV DOCKER_BUILDTAGS" set in our Dockerfile, which is very important for our official builds |
48 | 49 |
|
49 | 50 |
# to allow `make BIND_DIR=. shell` or `make BIND_DIR= test` |
... | ... |
@@ -67,7 +67,7 @@ DEFAULT_BUNDLES=( |
67 | 67 |
tgz |
68 | 68 |
) |
69 | 69 |
|
70 |
-VERSION=$(< ./VERSION) |
|
70 |
+VERSION=${VERSION:-$(< ./VERSION)} |
|
71 | 71 |
! BUILDTIME=$(date -u -d "@${SOURCE_DATE_EPOCH:-$(date +%s)}" --rfc-3339 ns 2> /dev/null | sed -e 's/ /T/') |
72 | 72 |
if [ "$DOCKER_GITCOMMIT" ]; then |
73 | 73 |
GITCOMMIT="$DOCKER_GITCOMMIT" |