Merge branch 'master' of https://mygit.wmg.warwick.ac.uk/u5500327/wmgzon
This commit is contained in:
commit
01cf5d641b
@ -2,10 +2,32 @@ variables:
|
|||||||
APPSECRET: "test"
|
APPSECRET: "test"
|
||||||
ENVIRON: "test"
|
ENVIRON: "test"
|
||||||
FILESTORE: "static/assets/img/products/"
|
FILESTORE: "static/assets/img/products/"
|
||||||
|
DOCKER_HOST: tcp://docker:2375/
|
||||||
|
DOCKER_DRIVER: overlay2
|
||||||
|
DOCKER_TLS_CERTDIR: ""
|
||||||
|
|
||||||
pytest:
|
pytest:
|
||||||
stage: test
|
stage: test
|
||||||
|
tags:
|
||||||
|
- python
|
||||||
script:
|
script:
|
||||||
- cd /builds/u5500327/wmgzon
|
- cd /builds/u5500327/wmgzon
|
||||||
- pip install -r requirements.txt
|
- pip install -r requirements.txt
|
||||||
- pytest
|
- pytest
|
||||||
|
|
||||||
|
deploy:
|
||||||
|
stage: deploy
|
||||||
|
tags:
|
||||||
|
- docker
|
||||||
|
image: docker:20.10.16
|
||||||
|
services:
|
||||||
|
- name: docker:20.10.16-dind
|
||||||
|
alias: docker
|
||||||
|
script:
|
||||||
|
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
|
||||||
|
- docker build -t $CI_REGISTRY_IMAGE:$CI_COMMIT_SHORT_SHA .
|
||||||
|
- docker push $CI_REGISTRY_IMAGE:$CI_COMMIT_SHORT_SHA
|
||||||
|
- docker tag $CI_REGISTRY_IMAGE:$CI_COMMIT_SHORT_SHA $CI_REGISTRY_IMAGE:latest
|
||||||
|
- docker push $CI_REGISTRY_IMAGE:latest
|
||||||
|
only:
|
||||||
|
- master
|
@ -1,8 +1,15 @@
|
|||||||
version: '3.8'
|
version: '3.8'
|
||||||
services:
|
services:
|
||||||
gitlab-runner:
|
gitlab-runner-python:
|
||||||
image: gitlab/gitlab-runner:latest
|
image: gitlab/gitlab-runner:latest
|
||||||
volumes:
|
volumes:
|
||||||
- ./runner-data:/etc/gitlab-runner
|
- ./runner-data-python:/etc/gitlab-runner
|
||||||
|
- /var/run/docker.sock:/var/run/docker.sock
|
||||||
|
restart: unless-stopped
|
||||||
|
|
||||||
|
gitlab-runner-docker:
|
||||||
|
image: gitlab/gitlab-runner:latest
|
||||||
|
volumes:
|
||||||
|
- ./runner-data-docker:/etc/gitlab-runner
|
||||||
- /var/run/docker.sock:/var/run/docker.sock
|
- /var/run/docker.sock:/var/run/docker.sock
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
Loading…
Reference in New Issue
Block a user