commit 4bc4ac4ca47b60cc61ef2e21c616206442952fff Author: td-wenchao Date: Fri Mar 22 09:02:00 2024 +0000 添加 悟空升级后pipeline 示例 diff --git a/%E6%82%9F%E7%A9%BA%E5%8D%87%E7%BA%A7%E5%90%8Epipeline-%E7%A4%BA%E4%BE%8B.md b/%E6%82%9F%E7%A9%BA%E5%8D%87%E7%BA%A7%E5%90%8Epipeline-%E7%A4%BA%E4%BE%8B.md new file mode 100644 index 0000000..e4c0a90 --- /dev/null +++ b/%E6%82%9F%E7%A9%BA%E5%8D%87%E7%BA%A7%E5%90%8Epipeline-%E7%A4%BA%E4%BE%8B.md @@ -0,0 +1,65 @@ +悟空升级后,ci后端采用k8s,变化较大,下面是使用示例 +更详细信息请访问https://woodpecker-ci.org/docs/intro + + + +``` +variables: + - &platforms linux/arm64/v8,linux/amd64 + +clone: + - name: git + image: harbor.tdology.com/woodpeckerci/plugin-git + settings: + skip-verify: true + remote: https://wukong.tdology.com/picloud/gitea.git + when: + event: + - pull_request + - tag + +steps: + - name: build + image: harbor.tdology.com/woodpeckerci/plugin-docker-buildx:3.1.0 + privileged: true + settings: + buildkit_driveropt: + - "image=harbor.tdology.com/moby/buildkit:buildx-stable-1" + mirror: harbor.tdology.com + registry: harbor.tdology.com + repo: harbor.tdology.com/gitea/gitea + dockerfile: Dockerfile + platforms: *platforms + tags: latest,v1-${CI_COMMIT_SHA:0:8} + context: . + username: + from_secret: harbor-user + password: + from_secret: harbor-pass + when: + event: + - pull_request + + - name: release + image: harbor.tdology.com/woodpeckerci/plugin-docker-buildx:3.1.0 + privileged: true + settings: + buildkit_driveropt: + - "image=harbor.tdology.com/moby/buildkit:buildx-stable-1" + mirror: harbor.tdology.com + registry: harbor.tdology.com + repo: harbor.tdology.com/gitea/gitea + auto_tag: true + dockerfile: Dockerfile + platforms: *platforms + context: . + mtu: 1400 + username: + from_secret: harbor-user + password: + from_secret: harbor-pass + when: + event: + - tag + +```