new test for drone
This commit is contained in:
parent
fa50a2d618
commit
9c1057d1ce
34
.drone.yml
34
.drone.yml
@ -1,35 +1,45 @@
|
|||||||
|
global-variables:
|
||||||
|
env: &env
|
||||||
|
image: golang
|
||||||
|
commands:
|
||||||
|
- go build -ldflags "-X main.version=${DRONE_TAG##v}" -o release/$GOOS/$GOARCH/ubnt-freifunk-map-api .
|
||||||
|
- tar -cvzf release/ubnt-freifunk-map-api_$GOOS_$GOARCH.tar.gz -C release/$GOOS/$GOARCH ubnt-freifunk-map-api
|
||||||
|
|
||||||
kind: pipeline
|
kind: pipeline
|
||||||
type: docker
|
type: docker
|
||||||
name: build go
|
name: build go
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: build linux/amd64
|
- name: build linux/amd64
|
||||||
image: golang
|
<<: *env
|
||||||
commands:
|
|
||||||
- go build -ldflags "-X main.version=${DRONE_TAG}" -o release/linux/amd64/ubnt-freifunk-map-api .
|
|
||||||
- tar -cvzf release/ubnt-freifunk-map-api_linux_amd64.tar.gz -C release/linux/amd64 ubnt-freifunk-map-api
|
|
||||||
environment:
|
environment:
|
||||||
GOARCH: amd64
|
GOARCH: amd64
|
||||||
GOOS: linux
|
GOOS: linux
|
||||||
|
|
||||||
- name: build linux/arm64
|
- name: build linux/arm64
|
||||||
image: golang
|
<<: *env
|
||||||
commands:
|
|
||||||
- go build -ldflags "-X main.version=${DRONE_TAG}" -o release/linux/arm64/ubnt-freifunk-map-api .
|
|
||||||
- tar -cvzf release/ubnt-freifunk-map-api_linux_arm64.tar.gz -C release/linux/arm64 ubnt-freifunk-map-api
|
|
||||||
environment:
|
environment:
|
||||||
GOARCH: arm64
|
GOARCH: arm64
|
||||||
GOOS: linux
|
GOOS: linux
|
||||||
|
|
||||||
- name: build windows
|
- name: build windows
|
||||||
image: golang
|
<<: *env
|
||||||
commands:
|
|
||||||
- go build -ldflags "-X main.version=${DRONE_TAG}" -o release/windows/amd64/ubnt-freifunk-map-api .
|
|
||||||
- tar -cvzf release/ubnt-freifunk-map-api_windows_amd64.tar.gz -C release/windows/amd64 ubnt-freifunk-map-api
|
|
||||||
environment:
|
environment:
|
||||||
GOARCH: amd64
|
GOARCH: amd64
|
||||||
GOOS: windows
|
GOOS: windows
|
||||||
|
|
||||||
|
- name: build macos/x64
|
||||||
|
<<: *env
|
||||||
|
environment:
|
||||||
|
GOARCH: amd64
|
||||||
|
GOOS: darwin
|
||||||
|
|
||||||
|
- name: build macos/arm64
|
||||||
|
<<: *env
|
||||||
|
environment:
|
||||||
|
GOARCH: arm64
|
||||||
|
GOOS: darwin
|
||||||
|
|
||||||
- name: docker
|
- name: docker
|
||||||
image: plugins/docker
|
image: plugins/docker
|
||||||
settings:
|
settings:
|
||||||
|
Loading…
Reference in New Issue
Block a user