Swap build and test stage
This commit is contained in:
parent
103ea70f9a
commit
cffaafb6bd
|
|
@ -1,16 +1,8 @@
|
|||
stages:
|
||||
- test
|
||||
- build
|
||||
- test
|
||||
- deploy
|
||||
|
||||
rails spec:
|
||||
stage: test
|
||||
image: ruby:2.6.2
|
||||
script:
|
||||
- bundle install --path /cache
|
||||
- bundle exec rails db:migrate RAILS_ENV=test
|
||||
- bundle exec rails spec
|
||||
|
||||
kaniko:
|
||||
stage: build
|
||||
image:
|
||||
|
|
@ -22,6 +14,14 @@ kaniko:
|
|||
- /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/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
|
||||
|
||||
rails spec:
|
||||
stage: test
|
||||
image: ruby:2.6.2
|
||||
script:
|
||||
- bundle install --path /cache
|
||||
- bundle exec rails db:migrate RAILS_ENV=test
|
||||
- bundle exec rails spec
|
||||
|
||||
kubernetes:
|
||||
stage: deploy
|
||||
only:
|
||||
|
|
|
|||
Loading…
Reference in New Issue