Pass CI_JOB_ID to docker container

This commit is contained in:
Tom Jack 2019-12-16 14:33:16 -06:00
parent c83813456a
commit 3110ae87e1
2 changed files with 4 additions and 1 deletions

View File

@ -1,6 +1,9 @@
ARG target ARG target
FROM ocaml/opam2:${target} FROM ocaml/opam2:${target}
ARG ci_job_id
ENV CI_JOB_ID=$ci_job_id
RUN opam switch 4.07 && eval $(opam env) RUN opam switch 4.07 && eval $(opam env)
USER root USER root

View File

@ -8,4 +8,4 @@ dockerfile="./docker/distribution/generic/build.Dockerfile"
echo "Building LIGO for $target" echo "Building LIGO for $target"
echo "Using Dockerfile: $dockerfile" echo "Using Dockerfile: $dockerfile"
echo "Tagging as: $tag_build\n" echo "Tagging as: $tag_build\n"
docker build --build-arg target="$target" -t "$tag_build" -f "$dockerfile" . docker build --build-arg ci_job_id="${CI_JOB_ID}" --build-arg target="$target" -t "$tag_build" -f "$dockerfile" .