Tag local versions of Docker Containers
These are (hopefully) never pushed and therefore are always the most recent version.
This commit is contained in:
parent
d507f84dc8
commit
c22aafe037
|
|
@ -10,9 +10,9 @@ kaniko:
|
||||||
entrypoint: [""]
|
entrypoint: [""]
|
||||||
script:
|
script:
|
||||||
- echo "{\"auths\":{\"$CI_REGISTRY\":{\"username\":\"$CI_REGISTRY_USER\",\"password\":\"$CI_REGISTRY_PASSWORD\"}}}" > /kaniko/.docker/config.json
|
- echo "{\"auths\":{\"$CI_REGISTRY\":{\"username\":\"$CI_REGISTRY_USER\",\"password\":\"$CI_REGISTRY_PASSWORD\"}}}" > /kaniko/.docker/config.json
|
||||||
- /kaniko/executor --context $CI_PROJECT_DIR --dockerfile $CI_PROJECT_DIR/docker/production/Dockerfile --destination $CI_REGISTRY_IMAGE/production --destination $CI_REGISTRY_IMAGE/production/commits:$CI_COMMIT_SHA --destination $CI_REGISTRY_IMAGE/production/branches:$CI_COMMIT_REF_SLUG
|
- /kaniko/executor --context $CI_PROJECT_DIR --dockerfile $CI_PROJECT_DIR/docker/production/Dockerfile --destination $CI_REGISTRY_IMAGE/production --destination $CI_REGISTRY_IMAGE/production/commits:$CI_COMMIT_SHA --destination $CI_REGISTRY_IMAGE/production/branches:$CI_COMMIT_REF_SLUG --destination turniere-backend/production:local
|
||||||
- /kaniko/executor --context $CI_PROJECT_DIR --dockerfile $CI_PROJECT_DIR/docker/development/Dockerfile --destination $CI_REGISTRY_IMAGE/development --destination $CI_REGISTRY_IMAGE/development/commits:$CI_COMMIT_SHA --destination $CI_REGISTRY_IMAGE/development/branches:$CI_COMMIT_REF_SLUG
|
- /kaniko/executor --context $CI_PROJECT_DIR --dockerfile $CI_PROJECT_DIR/docker/development/Dockerfile --destination $CI_REGISTRY_IMAGE/development --destination $CI_REGISTRY_IMAGE/development/commits:$CI_COMMIT_SHA --destination $CI_REGISTRY_IMAGE/development/branches:$CI_COMMIT_REF_SLUG --destination turniere-backend/development:local
|
||||||
- /kaniko/executor --context $CI_PROJECT_DIR --dockerfile $CI_PROJECT_DIR/docker/test/Dockerfile --destination $CI_REGISTRY_IMAGE/test --destination $CI_REGISTRY_IMAGE/test/commits:$CI_COMMIT_SHA --destination $CI_REGISTRY_IMAGE/test/branches:$CI_COMMIT_REF_SLUG
|
- /kaniko/executor --context $CI_PROJECT_DIR --dockerfile $CI_PROJECT_DIR/docker/test/Dockerfile --destination $CI_REGISTRY_IMAGE/test --destination $CI_REGISTRY_IMAGE/test/commits:$CI_COMMIT_SHA --destination $CI_REGISTRY_IMAGE/test/branches:$CI_COMMIT_REF_SLUG --destination turniere-backend/test:local
|
||||||
|
|
||||||
rails spec:
|
rails spec:
|
||||||
stage: test
|
stage: test
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
# Build production container locally first with following tag
|
# Build production container locally first with following tag
|
||||||
FROM registry.gitlab.com/turniere/turniere-backend/production
|
FROM turniere-backend/production:local
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
RUN bundle install --deployment --with development
|
RUN bundle install --deployment --with development
|
||||||
ENV RAILS_ENV development
|
ENV RAILS_ENV development
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
# Build development container locally first with following tag
|
# Build development container locally first with following tag
|
||||||
FROM registry.gitlab.com/turniere/turniere-backend/development
|
FROM turniere-backend/development:local
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
RUN bundle install --deployment --with test
|
RUN bundle install --deployment --with test
|
||||||
ENV RAILS_ENV test
|
ENV RAILS_ENV test
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue