updated .drone.yml
Some checks failed
continuous-integration/drone/push Build is passing
continuous-integration/drone/tag Build is failing

This commit is contained in:
Paul 2022-10-30 15:02:20 +01:00
parent cb8afd898a
commit ebb81c3222

View File

@ -1,42 +1,33 @@
--- ---
kind: pipeline kind: pipeline
type: docker type: docker
name: build-linux-amd64 name: build-linux
steps:
- name: build-linux-amd64
image: golang
commands:
- go build -o $PROJECTNAME $GOOPTIONS $SRCFILES
environment: environment:
GOOS: linux GOOS: linux
GOARCH: amd64 GOARCH: amd64
GOOPTIONS: -mod=vendor GOOPTIONS: -mod=vendor
SRCFILES: cmd/qrz/*.go SRCFILES: cmd/qrz/*.go
PROJECTNAME: qrz PROJECTNAME: qrz
steps:
- name: build
image: golang
commands:
- go build -o $PROJECTNAME $GOOPTIONS $SRCFILES
when: when:
event: event:
exclude: exclude:
- tag - tag
- name: build-linux-arm64
--- image: golang
kind: pipeline commands:
type: docker - go build -o $PROJECTNAME $GOOPTIONS $SRCFILES
name: build-linux-arm64
environment: environment:
GOOS: linux GOOS: linux
GOARCH: arm64 GOARCH: arm64
GOOPTIONS: -mod=vendor GOOPTIONS: -mod=vendor
SRCFILES: cmd/qrz/*.go SRCFILES: cmd/qrz/*.go
PROJECTNAME: qrz PROJECTNAME: qrz
steps:
- name: build
image: golang
commands:
- go build -o $PROJECTNAME $GOOPTIONS $SRCFILES
when: when:
event: event:
exclude: exclude:
@ -45,59 +36,36 @@ steps:
--- ---
kind: pipeline kind: pipeline
type: docker type: docker
name: gitea-release-linux-amd64 name: gitea-release-linux
steps:
- name: build-linux-amd64
image: golang
commands:
- go build -o $PROJECTNAME $GOOPTIONS $SRCFILES
- tar -czvf $PROJECTNAME-$DRONE_TAG-$GOOS-$GOARCH.tar.gz $PROJECTNAME
- echo $PROJECTNAME $DRONE_TAG > VERSION
environment: environment:
GOOS: linux GOOS: linux
GOARCH: amd64 GOARCH: amd64
GOOPTIONS: -mod=vendor -ldflags="-s -w" GOOPTIONS: -mod=vendor -ldflags="-s -w"
SRCFILES: cmd/qrz/*.go SRCFILES: cmd/qrz/*.go
PROJECTNAME: qrz PROJECTNAME: qrz
when:
steps: event:
- name: build - tag
image: golang - name: build-linux-arm64
commands:
- go build -o $PROJECTNAME $GOOPTIONS $SRCFILES
- tar -czvf $PROJECTNAME-$DRONE_TAG-$GOOS-$GOARCH.tar.gz $PROJECTNAME
- echo $PROJECTNAME $DRONE_TAG > VERSION
when:
event:
- tag
- name: release
image: plugins/gitea-release
settings:
base_url: https://git.paulbsd.com
api_key:
from_secret: gitea_token
files: "*.tar.gz"
checksum:
- sha256
- sha512
title: VERSION
when:
event:
- tag
---
kind: pipeline
type: docker
name: gitea-release-linux-arm64
environment:
GOOS: linux
GOARCH: arm64
GOOPTIONS: -mod=vendor -ldflags="-s -w"
SRCFILES: cmd/qrz/*.go
PROJECTNAME: qrz
steps:
- name: build
image: golang image: golang
commands: commands:
- go build -o $PROJECTNAME $GOOPTIONS $SRCFILES - go build -o $PROJECTNAME $GOOPTIONS $SRCFILES
- tar -czvf $PROJECTNAME-$DRONE_TAG-$GOOS-$GOARCH.tar.gz $PROJECTNAME - tar -czvf $PROJECTNAME-$DRONE_TAG-$GOOS-$GOARCH.tar.gz $PROJECTNAME
- echo $PROJECTNAME $DRONE_TAG > VERSION - echo $PROJECTNAME $DRONE_TAG > VERSION
environment:
GOOS: linux
GOARCH: arm64
GOOPTIONS: -mod=vendor -ldflags="-s -w"
SRCFILES: cmd/qrz/*.go
PROJECTNAME: qrz
when: when:
event: event:
- tag - tag