Commit 12f75eee authored by kaiyou's avatar kaiyou Committed by ayiniho
Browse files

Use kaniko in the CI file

parent b142271f
variables:
DOCKER_ORG: mailu
build:
stage: build
image:
name: gcr.io/kaniko-project/executor:debug
entrypoint: [""]
script:
- docker-compose -f tests/build.yml build
- docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" "$CI_REGISTRY"
- docker-compose -f tests/build.yml push
- echo "{\"auths\":{\"$CI_REGISTRY\":{\"username\":\"$CI_REGISTRY_USER\",\"password\":\"$CI_REGISTRY_PASSWORD\"}}}" > /kaniko/.docker/config.json
- /kaniko/executor --context $CI_PROJECT_DIR/core/nginx --dockerfile $CI_PROJECT_DIR/core/nginx/Dockerfile --destination $CI_REGISTRY_IMAGE/nginx:$CI_COMMIT_REF_SLUG
- /kaniko/executor --context $CI_PROJECT_DIR/core/dovecot --dockerfile $CI_PROJECT_DIR/core/dovecot/Dockerfile --destination $CI_REGISTRY_IMAGE/dovecot:$CI_COMMIT_REF_SLUG
- /kaniko/executor --context $CI_PROJECT_DIR/core/postfix --dockerfile $CI_PROJECT_DIR/core/postfix/Dockerfile --destination $CI_REGISTRY_IMAGE/postfix:$CI_COMMIT_REF_SLUG
- /kaniko/executor --context $CI_PROJECT_DIR/core/rspamd --dockerfile $CI_PROJECT_DIR/core/rspamd/Dockerfile --destination $CI_REGISTRY_IMAGE/rspamd:$CI_COMMIT_REF_SLUG
- /kaniko/executor --context $CI_PROJECT_DIR/core/admin --dockerfile $CI_PROJECT_DIR/core/admin/Dockerfile --destination $CI_REGISTRY_IMAGE/admin:$CI_COMMIT_REF_SLUG
- /kaniko/executor --context $CI_PROJECT_DIR/webmails/rainloop --dockerfile $CI_PROJECT_DIR/webmails/rainloop/Dockerfile --destination $CI_REGISTRY_IMAGE/rainloop:$CI_COMMIT_REF_SLUG
only:
- branches
Supports Markdown
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