更改yml
This commit is contained in:
parent
8ecb20a504
commit
496291a5a9
@ -9,11 +9,8 @@ variables:
|
||||
|
||||
stages:
|
||||
- build
|
||||
- clear_test
|
||||
- test
|
||||
- clear
|
||||
- deploy
|
||||
- clear_test
|
||||
|
||||
build:
|
||||
stage: build
|
||||
@ -29,18 +26,6 @@ build:
|
||||
- docker push ${IMAGE_NAME}
|
||||
- docker rmi ${IMAGE_NAME}
|
||||
|
||||
test:
|
||||
stage: test
|
||||
tags:
|
||||
- dockerbase
|
||||
script:
|
||||
- ls -a
|
||||
- docker login --username=${DOCKER_USERNAME} --password=${DOCKER_PASSWORD} ${DOCKER_REGION}
|
||||
- docker pull ${IMAGE_NAME}
|
||||
- docker run -d --name ${APP_NAME} -p 8080:80 ${IMAGE_NAME}
|
||||
cache:
|
||||
policy: pull
|
||||
|
||||
clear_master:
|
||||
stage: clear
|
||||
tags:
|
||||
@ -51,7 +36,6 @@ clear_master:
|
||||
- docker stop pan_${APP_NAME}
|
||||
- docker rm pan_${APP_NAME}
|
||||
allow_failure: true
|
||||
when: manual
|
||||
|
||||
deploy_master:
|
||||
stage: deploy
|
||||
@ -66,7 +50,6 @@ deploy_master:
|
||||
- docker run -d --name pan_${APP_NAME} -p 127.0.0.1:5005:80 ${IMAGE_NAME}
|
||||
cache:
|
||||
policy: pull
|
||||
when: manual
|
||||
|
||||
clear_outside:
|
||||
stage: clear
|
||||
@ -78,7 +61,6 @@ clear_outside:
|
||||
- docker stop ${APP_NAME}
|
||||
- docker rm ${APP_NAME}
|
||||
allow_failure: true
|
||||
when: manual
|
||||
|
||||
deploy_outside:
|
||||
stage: deploy
|
||||
@ -92,15 +74,4 @@ deploy_outside:
|
||||
- docker pull ${IMAGE_NAME}
|
||||
- docker run -d --name ${APP_NAME} -p 127.0.0.1:5004:80 ${IMAGE_NAME}
|
||||
cache:
|
||||
policy: pull
|
||||
when: manual
|
||||
|
||||
clear_test:
|
||||
stage: clear_test
|
||||
tags:
|
||||
- dockerbase
|
||||
script:
|
||||
- docker stop ${APP_NAME}
|
||||
- docker rm ${APP_NAME}
|
||||
allow_failure: true
|
||||
when: manual
|
||||
policy: pull
|
Loading…
x
Reference in New Issue
Block a user