新增流水自动部署

This commit is contained in:
XieHaoLiang 2024-12-27 09:10:55 +08:00
parent 4933c31e28
commit 1f6eee9b7d

50
.gitlab-ci.yml Normal file
View File

@ -0,0 +1,50 @@
variables:
PROJECT_DIR: "starcloud-sdk-uniapp"
stages:
- deploy
update-code-dev:
rules:
- if: '$CI_COMMIT_BRANCH == "web-develop"'
stage: deploy
tags:
- deploy
- dev
variables:
GIT_STRATEGY: none
script:
- cd ${WEBROOT_PATH}/${PROJECT_DIR} && git pull
update-code-pre:
rules:
- if: '$CI_COMMIT_BRANCH == "web-release"'
stage: deploy
tags:
- deploy
- pre
variables:
GIT_STRATEGY: none
script:
- cd ${WEBROOT_PATH}/${PROJECT_DIR} && git pull
update-code-xhj:
rules:
- if: '$CI_COMMIT_BRANCH == "web-master"'
stage: deploy
tags:
- deploy
- xhj
variables:
GIT_STRATEGY: none
script:
- cd ${WEBROOT_PATH}/${PROJECT_DIR} && git pull
update-code-sky:
rules:
- if: '$CI_COMMIT_BRANCH == "web-master"'
stage: deploy
tags:
- deploy
- sky
variables:
GIT_STRATEGY: none
script:
- cd ${WEBROOT_PATH}/${PROJECT_DIR} && git pull