云效使用 发表于 2023-12-25 | 分类于 services 云效地址https://codeup.aliyun.com/ 主要使用代码管理, 流水线 等 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798sources: repo_0: type: codeup name: xxx-prod endpoint: https://codeup.aliyun.com/xxx/xxx/xxx.git branch: main certificate: type: serviceConnection serviceConnection: xxxxdefaultWorkspace: repo_0stages: stage_0: name: 构建 jobs: job_0: name: Docker 镜像构建 runsOn: group: public/cn-hongkong labels: linux,amd64 instanceType: DEFAULT timeoutMinutes: 20 steps: step_0: name: 镜像构建并推送至镜像仓库 step: ACRDockerBuild with: artifact: artifact variables: [] dockerfilePath: Dockerfile noCache: false dockerRegistry: registry.cn-shenzhen.aliyuncs.com/xxx/${CI_SOURCE_NAME} buildkitVersion: v0.11.6 dockerTag: ${CI_COMMIT_REF_NAME}-${CI_COMMIT_ID}_${DATETIME} region: cn-shenzhen serviceConnection: xxx extraTags: - ${CI_COMMIT_REF_NAME}-latest driven: auto plugins: - name: 企业微信机器人通知插件 plugin: WechatPlugin triggerState: - fail with: noticeContent: - pipelineName - pipelineEnvironment - pipelineTag - pipelineRunRemark - triggerInfo - operator - pipelineJob - pipelineStage - status webhook: https://qyapi.weixin.qq.com/cgi-bin/webhook/send?key=xxxx stage_1: name: 部署 jobs: job_1: name: Kubernetes 镜像升级 runsOn: group: public/cn-hongkong labels: linux,amd64 instanceType: DEFAULT timeoutMinutes: 15 steps: step_0: name: Kubectl镜像升级 step: KubectlSetImage with: container: xxx artifact: $[stages.stage_0.job_0.step_0.artifacts.artifact] workloadKind: deployment skipTlsVerify: false kubernetesCluster: xxx namespace: xxx workload: xxx kubectlVersion: 1.27.9 rolloutTimeout: 10 driven: auto plugins: - name: 企业微信机器人通知插件 plugin: WechatPlugin triggerState: - fail - success with: noticeContent: - pipelineName - pipelineEnvironment - pipelineTag - pipelineRunRemark - triggerInfo - operator - pipelineJob - pipelineStage - status webhook: https://qyapi.weixin.qq.com/cgi-bin/webhook/send?key=xxx