代码拉取完成,页面将自动刷新
同步操作将从 neruuuuuuu/r5-shop-vue 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
pipeline {
agent any
stages {
stage('Install') {
steps {
echo 'Installing..'
sh 'npm install'
}
}
stage('Build') {
steps {
echo 'Building..'
sh 'npm run-script build'
}
}
stage('Archive') {
steps {
echo 'Archiving..'
archiveArtifacts artifacts: 'dist/', followSymlinks: false
}
}
stage('Deploy') {
/**
* Deploy to Tencent COS
* needed coscmd, before deploy remeber to install it on agent environment by `pip install coscmd`
*/
environment {
COS_SECRET_ID = credentials('r5-shop-cos-secret-id')
COS_SECRET_KEY = credentials('r5-shop-cos-secret-key')
COS_BUCKET = credentials('r5-shop-cos-bucket')
COS_REGION = credentials('r5-shop-cos-region')
}
steps {
echo 'Deploying....'
sh 'coscmd config -a ${COS_SECRET_ID} -s ${COS_SECRET_KEY} -b ${COS_BUCKET} -r ${COS_REGION}'
sh 'yes | coscmd -d upload -rs --delete dist/ /' //yes for "WARN: you are deleting some files in the '' cos_path, please make sure [y/N] "
}
}
stage('Clean') {
steps {
sh 'rm ~/.cos.conf' //clean the cos config include secret app key
}
}
}
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。