Commit 7bfec78e authored by Guillaume Vandevelde's avatar Guillaume Vandevelde
Browse files

[deploy] Add kaniko build

parent 67f0f7a7e5e7
Pipeline #40120 passed with stages
in 1 minute and 39 seconds
image: python:3.7
before_script:
- pip install tox
stages:
- test
- release
.test:
stage: test
before_script:
- pip install tox
check-manifest:
extends: .test
script: tox -e check-manifest
flake8:
extends: .test
script: tox -e flake8
py3:
extends: .test
script: tox -e py3
artifacts:
paths:
- py3-deprecated-warnings.json
yamllint:
extends: .test
rules:
- changes:
- "**/*.yaml"
......@@ -24,3 +34,25 @@ yamllint:
- "*.yml"
script:
- tox -e yamllint
image_build:
stage: release
image:
name: gcr.io/kaniko-project/executor:debug
entrypoint: [""]
script:
- 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/Dockerfile --destination $CI_REGISTRY_IMAGE:$CI_COMMIT_HG_SHORT_SHA
rules:
- if: '$CI_COMMIT_REF_NAME != "branch/default"'
image_build_latest:
stage: release
image:
name: gcr.io/kaniko-project/executor:debug
entrypoint: [""]
script:
- 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/Dockerfile --destination $CI_REGISTRY_IMAGE:$CI_COMMIT_HG_SHORT_SHA --destination $CI_REGISTRY_IMAGE:latest
rules:
- if: '$CI_COMMIT_REF_NAME == "branch/default"'
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