gocos/.drone.yml

32 lines
908 B
YAML
Raw Normal View History

2020-12-24 10:10:59 +08:00
kind: pipeline
name: default
2023-07-07 01:28:01 +08:00
node:
2023-07-07 02:28:15 +08:00
region: cn
2020-12-24 10:10:59 +08:00
steps:
- name: build
pull: if-not-exists
2023-07-07 01:28:01 +08:00
image: ccr.ccs.tencentyun.com/xiaoqidun/goenv
2020-12-24 10:10:59 +08:00
commands:
2024-01-10 11:42:19 +08:00
- GOAMD64=v3 CGO_ENABLED=0 go build -o gocos -trimpath -ldflags "-s -w -buildid=" gocos.go
2023-07-07 01:28:01 +08:00
- name: docker-cn
pull: if-not-exists
image: plugins/docker
settings:
repo: ccr.ccs.tencentyun.com/xiaoqidun/gocos
registry: ccr.ccs.tencentyun.com
username:
from_secret: docker_username
password:
from_secret: docker_password
dockerfile: Dockerfile
- name: docker-hk
2020-12-24 10:10:59 +08:00
pull: if-not-exists
image: plugins/docker
settings:
2021-09-22 09:46:02 +08:00
repo: hkccr.ccs.tencentyun.com/xiaoqidun/gocos
registry: hkccr.ccs.tencentyun.com
2020-12-24 10:10:59 +08:00
username:
from_secret: docker_username
password:
from_secret: docker_password
2023-07-07 01:28:01 +08:00
dockerfile: Dockerfile