mirror of https://github.com/certd/certd
perf: 部署到腾讯云cdn,每个域名增加3每秒延迟
parent
a77c777980
commit
f7d43ad5af
|
@ -0,0 +1,37 @@
|
||||||
|
name: sync-to-gitee-dev
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: ['v2-dev']
|
||||||
|
paths:
|
||||||
|
- "build.trigger"
|
||||||
|
# schedule:
|
||||||
|
# - # 国际时间 19:17 执行,北京时间3:17 ↙↙↙ 改成你想要每天自动执行的时间
|
||||||
|
# - cron: '17 19 * * *'
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
sync:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout work repo # 1. 检出当前仓库(certd-sync-work)
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
lfs: true
|
||||||
|
- name: Set git user # 2. 给git命令设置用户名和邮箱,↙↙↙ 改成你的name和email
|
||||||
|
run: |
|
||||||
|
git config --global user.name "xiaojunnuo"
|
||||||
|
git config --global user.email "xiaojunnuo@qq.com"
|
||||||
|
|
||||||
|
- name: Set git token # 3. 给git命令设置token,用于push到目标仓库
|
||||||
|
uses: de-vri-es/setup-git-credentials@v2
|
||||||
|
with: # token 格式为: username:password
|
||||||
|
credentials: https://${{secrets.PUSH_TOKEN_GITEE}}@gitee.com
|
||||||
|
|
||||||
|
- name: push to gitee # 4. 执行同步
|
||||||
|
run: |
|
||||||
|
sleep 10
|
||||||
|
git remote add upstream https://gitee.com/certd/certd
|
||||||
|
git push --set-upstream upstream v2-dev
|
||||||
|
|
|
@ -80,6 +80,8 @@ export class TencentDeployCertToCDNv2 extends AbstractTaskPlugin {
|
||||||
InstanceIdList: this.domains,
|
InstanceIdList: this.domains,
|
||||||
});
|
});
|
||||||
|
|
||||||
|
await this.ctx.utils.sleep(3000)
|
||||||
|
|
||||||
this.logger.info('部署成功', res);
|
this.logger.info('部署成功', res);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue