|
@ -19,6 +19,8 @@ steps: |
|
|
- go mod init test-drone |
|
|
- go mod init test-drone |
|
|
- go mod tidy |
|
|
- go mod tidy |
|
|
- CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o test-drone |
|
|
- CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o test-drone |
|
|
|
|
|
when: |
|
|
|
|
|
target: [ "test","pre" ] |
|
|
|
|
|
|
|
|
- name: docker-build |
|
|
- name: docker-build |
|
|
image: plugins/docker |
|
|
image: plugins/docker |
|
@ -29,6 +31,8 @@ steps: |
|
|
dockerfile: Dockerfile |
|
|
dockerfile: Dockerfile |
|
|
registry: https://registry.cn-hangzhou.aliyuncs.com |
|
|
registry: https://registry.cn-hangzhou.aliyuncs.com |
|
|
tags: ${DRONE_BUILD_NUMBER} |
|
|
tags: ${DRONE_BUILD_NUMBER} |
|
|
|
|
|
when: |
|
|
|
|
|
target: [ "test","pre" ] |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# - name: rancher-push |
|
|
# - name: rancher-push |
|
@ -52,3 +56,6 @@ steps: |
|
|
username: tjqmhu |
|
|
username: tjqmhu |
|
|
password: tjqm4912 |
|
|
password: tjqm4912 |
|
|
registry: https://registry.cn-hangzhou.aliyuncs.com |
|
|
registry: https://registry.cn-hangzhou.aliyuncs.com |
|
|
|
|
|
when: |
|
|
|
|
|
target: [ "test","pre" ] |
|
|
|
|
|
|