lsf/.workflow/pipeline-vue.yml

61 lines
1.4 KiB
YAML
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

version: '1.0'
name: pipeline-vue
displayName: 部署前端
triggers:
trigger: auto
push:
branches:
precise:
- master
commitMessages:
include:
- ^deploy-vue
stages:
- name: stage-3761fd9a
displayName: 构建前端
strategy: naturally
trigger: auto
executor:
- kerwincui
steps:
- step: build@nodejs
name: build_nodejs
displayName: Nodejs 构建
nodeVersion: 14.16.0
commands:
- cd ./vue
- npm install --registry=https://registry.npm.taobao.org \
- '&& rm -rf ./dist && npm run build:prod'
artifacts:
- name: BUILD_VUE
path:
- ./vue/dist
strategy:
retry: '0'
- name: stage-79a96375
displayName: 部署前端
strategy: naturally
trigger: auto
executor:
- kerwincui
steps:
- step: deploy@agent
name: deploy_agent
displayName: 主机部署
hostGroupID: alicloud
deployArtifact:
- source: build
name: vue
target: ~/gitee_go/deploy
dependArtifact: BUILD_VUE
script: |-
# 请在此输入部署脚本如启动Java应用如下
# nohup java -jar test.jar > nohup.out &
echo 'Hello Gitee!' && touch vuetest
touch vue
strategy:
retry: '0'
permissions:
- role: admin
members: []