diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 4fc56ca16d62ffb4fab96d8f936eeeca2b55285e..69807abee7d99cddfd8257ca3429cd98f2d71fea 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -9,6 +9,7 @@ stages: format: image: golang:alpine stage: test + needs: [] before_script: - apk add build-base script: @@ -19,6 +20,7 @@ format: compile: image: golang:alpine stage: build + needs: [] before_script: - apk add build-base script: @@ -29,6 +31,7 @@ compile: build: stage: docker + needs: [ compile ] image: name: gcr.io/kaniko-project/executor:debug entrypoint: [""] @@ -47,3 +50,18 @@ build: EOF - /kaniko/executor --context $CI_PROJECT_DIR --dockerfile $CI_PROJECT_DIR/Dockerfile --destination $CI_REGISTRY_IMAGE:latest +kube: + stage: deploy + image: + name: bitnami/kubectl + entrypoint: [ "" ] + needs: [ "format", "build" ] + environment: + name: apps + kubernetes: + namespace: apps + script: + - kubectl rollout restart deployment vox + only: + refs: + - master