Verified Commit 9b45a95f authored by Jordan Petridіs's avatar Jordan Petridіs 🌱
Browse files

CI: only build the images that changed

previously when something in the docker/ direcotry was changed,
all of the images would be rebuilt.
parent cc5ff7d8
...@@ -58,11 +58,6 @@ test manifest: ...@@ -58,11 +58,6 @@ test manifest:
docker push ${REF} docker push ${REF}
docker push ${LATEST} docker push ${LATEST}
fi fi
only:
changes:
- ".gitlab-ci.yml"
- "docker/**"
- "docker/*/**"
alpine amd64 manifest builder docker: alpine amd64 manifest builder docker:
stage: "build runtime" stage: "build runtime"
...@@ -72,6 +67,10 @@ alpine amd64 manifest builder docker: ...@@ -72,6 +67,10 @@ alpine amd64 manifest builder docker:
CONTEXT_DIR: "docker/runtime-images/" CONTEXT_DIR: "docker/runtime-images/"
DOCKERFILE: "docker/runtime-images/Dockerfile-manifest-builder" DOCKERFILE: "docker/runtime-images/Dockerfile-manifest-builder"
extends: .base extends: .base
only:
changes:
- 'docker/runtime-images/Dockerfile-manifest-builder'
- 'gitlab/build_manifest.py'
fedora amd64 run docker: fedora amd64 run docker:
stage: "build runtime" stage: "build runtime"
...@@ -81,6 +80,9 @@ fedora amd64 run docker: ...@@ -81,6 +80,9 @@ fedora amd64 run docker:
CONTEXT_DIR: "docker/runtime-images/" CONTEXT_DIR: "docker/runtime-images/"
DOCKERFILE: "docker/runtime-images/Dockerfile-fedora" DOCKERFILE: "docker/runtime-images/Dockerfile-fedora"
extends: .base extends: .base
only:
changes:
- 'docker/runtime-images/Dockerfile-fedora'
fedora amd64 build docker: fedora amd64 build docker:
stage: "build base" stage: "build base"
...@@ -90,6 +92,9 @@ fedora amd64 build docker: ...@@ -90,6 +92,9 @@ fedora amd64 build docker:
CONTEXT_DIR: "docker/build-base-images/" CONTEXT_DIR: "docker/build-base-images/"
DOCKERFILE: "docker/build-base-images/Dockerfile-fedora" DOCKERFILE: "docker/build-base-images/Dockerfile-fedora"
extends: .base extends: .base
only:
changes:
- 'docker/build-base-images/Dockerfile-fedora'
include: "gitlab/ci_template.yml" include: "gitlab/ci_template.yml"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment