Parallelize CI a bit

This commit is contained in:
Aarni Halinen
2019-12-18 16:53:35 +02:00
parent d0216bb85c
commit f2ffcaa5a9
+7 -8
View File
@@ -1,12 +1,11 @@
stages:
- test
- lint
- qa
- publish
- deploy
test:
image: python:3.7
stage: test
stage: qa
services:
- postgres:12
variables:
@@ -24,14 +23,14 @@ test:
pycodestyle:
image: python:3.7
stage: lint
stage: qa
script:
- pip install pycodestyle
- pycodestyle --config=setup.cfg --count .
eslint:
image: node:alpine
stage: lint
stage: qa
before_script:
- npm install
script:
@@ -39,7 +38,7 @@ eslint:
remark:
image: node:alpine
stage: lint
stage: qa
before_script:
- npm install
script:
@@ -59,7 +58,7 @@ publish:
- docker build . -t "$IMAGE_NAME"
- docker push "$IMAGE_NAME"
deploy_dev:
deploy:dev:
stage: deploy
image: alpine:latest
environment:
@@ -82,7 +81,7 @@ deploy_dev:
- ssh $DEV_SSH_USER@$DEV_SSH_HOST "docker login -u gitlab-ci-token -p $CI_JOB_TOKEN $CI_REGISTRY"
- ssh $DEV_SSH_USER@$DEV_SSH_HOST "bash ~/deployment/deploy_dev.sh \"$IMAGE_NAME\""
deploy_production:
deploy:production:
stage: deploy
image: docker:stable
only: