updated .drone.yml
This commit is contained in:
parent
59a783efd8
commit
68ce22a4f0
20
.drone.yml
20
.drone.yml
@ -54,20 +54,34 @@ type: docker
|
||||
name: gitea-release
|
||||
|
||||
environment:
|
||||
GOOS: linux
|
||||
GOOPTIONS: -mod=vendor
|
||||
SRCFILES: cmd/go-aptproxy/*.go
|
||||
PROJECTNAME: go-aptproxy
|
||||
|
||||
steps:
|
||||
- name: build
|
||||
- name: build-amd64
|
||||
image: golang
|
||||
environment:
|
||||
GOARCH: amd64
|
||||
commands:
|
||||
- export VERSION=$DRONE_TAG
|
||||
- go generate $SRCFILES
|
||||
- go build -o $PROJECTNAME $GOOPTIONS $SRCFILES
|
||||
- tar -czvf $PROJECTNAME-$DRONE_TAG-linux-amd64.tar.gz $PROJECTNAME
|
||||
- tar -czvf $PROJECTNAME-$DRONE_TAG-$GOOS-$GOARCH.tar.gz $PROJECTNAME
|
||||
- echo $PROJECTNAME $DRONE_TAG > VERSION
|
||||
when:
|
||||
event:
|
||||
- tag
|
||||
- name: build-arm64
|
||||
image: golang
|
||||
environment:
|
||||
GOARCH: arm64
|
||||
commands:
|
||||
- export VERSION=$DRONE_TAG
|
||||
- go generate $SRCFILES
|
||||
- go build -o $PROJECTNAME $GOOPTIONS $SRCFILES
|
||||
- tar -czvf $PROJECTNAME-$DRONE_TAG-linux-arm64.tar.gz $PROJECTNAME
|
||||
- tar -czvf $PROJECTNAME-$DRONE_TAG-$GOOS-$GOARCH.tar.gz $PROJECTNAME
|
||||
- echo $PROJECTNAME $DRONE_TAG > VERSION
|
||||
when:
|
||||
event:
|
||||
|
Loading…
Reference in New Issue
Block a user