img_zip/.gitlab-ci.yml
2021-01-06 23:02:36 +08:00

38 lines
530 B
YAML

stages:
- build
- clear
- deploy
build:
stage: build
image: docker:latest
services:
- name: docker:dind
tags:
- dockerbase
script:
- ls -a
- docker build -t lacus/imgzip .
clear:
stage: clear
tags:
- dockerbase
only:
- master
script:
- docker stop imgzip
- docker rm imgzip
allow_failure: true
deploy:
stage: deploy
tags:
- dockerbase
only:
- master
script:
- ls -a
- docker run -d --name imgzip -p 5004:80 lacus/imgzip
cache:
policy: pull