Skip to content
Snippets Groups Projects

build the Dockerimage used in CI

Merged Bas Nijholt requested to merge docker into master
Compare and Show latest version
1 file
+ 9
21
Compare changes
  • Side-by-side
  • Inline
+ 9
21
@@ -5,28 +5,18 @@ stages:
- test
build docker:
stage:
- prebuild
stage: prebuild
image:
name: gcr.io/kaniko-project/executor:debug
name: docker:dind
entrypoint: [""]
before_script:
- docker login -u $CI_DEPLOY_USER -p $CI_DEPLOY_PASSWORD $CI_REGISTRY
- export CI_REF=${CI_COMMIT_TAG:-latest}
script:
- /kaniko/executor
--context $CI_PROJECT_DIR
--dockerfile $CI_PROJECT_DIR/Dockerfile
--destination $CI_REGISTRY_IMAGE:$CI_REF
only:
changes:
- Dockerfile
- environment.yml
- test-requirements.txt
- docker login -u $CI_DEPLOY_USER -p $CI_DEPLOY_PASSWORD $CI_REGISTRY
- docker build -t $CI_REGISTRY_IMAGE .
- docker push $CI_REGISTRY_IMAGE
test:
stage:
- test
stage: test
script:
- py.test --verbose --cov=adaptive --cov-report term --cov-report html adaptive
artifacts:
@@ -34,15 +24,13 @@ test:
- htmlcov
authors check:
stage:
- test
stage: test
script:
- MISSING_AUTHORS=$(git shortlog -s HEAD | sed -e "s/^[0-9\t ]*//"| xargs -i sh -c 'grep -q "{}" AUTHORS.md || echo "{} missing from authors"')
- if [ ! -z "$MISSING_AUTHORS" ]; then { echo $MISSING_AUTHORS; exit 1; }; fi
allow_failure: true
check whitespace style:
stage:
- test
stage: test
script: ./check_whitespace
allow_failure: true
Loading