Skip to content
Snippets Groups Projects
Commit 46dc0f30 authored by Luigi Sbailo's avatar Luigi Sbailo
Browse files

Add cachbust to dockerfile

parent 8095fca6
No related branches found
No related tags found
1 merge request!123testing develop merge
......@@ -60,7 +60,7 @@ build to production:
script:
# Using cache to speed up the build process
- docker pull ${CI_REGISTRY_IMAGE}:latest || true
- docker build --cache-from ${CI_REGISTRY_IMAGE}:latest --tag ${CI_REGISTRY_IMAGE}:production${CI_COMMIT_SHORT_SHA} --tag ${CI_REGISTRY_IMAGE}:latest .
- docker build --cache-from ${CI_REGISTRY_IMAGE}:latest --build-arg CACHEBUST=$(date +%s) --tag ${CI_REGISTRY_IMAGE}:production${CI_COMMIT_SHORT_SHA} --tag ${CI_REGISTRY_IMAGE}:latest .
- docker push ${CI_REGISTRY_IMAGE}:production${CI_COMMIT_SHORT_SHA}
- docker push ${CI_REGISTRY_IMAGE}:latest
rules:
......
......@@ -195,6 +195,9 @@ RUN pip install .
# Install all of the package dependencies of the tutorials
# ================================================================================
ARG CACHEBUST
RUN echo "$CACHEBUST"
WORKDIR /opt/tutorials
COPY tutorials/ .
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment