this should do, maybe
This commit is contained in:
parent
384cd4f483
commit
d7458d902e
@ -1,9 +1,7 @@
|
|||||||
local pipeline(arch, os) = {
|
local pipeline(arch, os) = {
|
||||||
kind: "pipeline",
|
name: "build" + os + "/" + arch,
|
||||||
type: "docker",
|
|
||||||
name: "build go",
|
|
||||||
steps: [{
|
steps: [{
|
||||||
name: "build " + os + "/" + arch,
|
name: "compile " + os + "/" + arch,
|
||||||
image: "golang:1.15.6-alpine3.12",
|
image: "golang:1.15.6-alpine3.12",
|
||||||
environment: {
|
environment: {
|
||||||
"GOOS": os,
|
"GOOS": os,
|
||||||
@ -11,7 +9,7 @@ local pipeline(arch, os) = {
|
|||||||
"CGO_ENABLED": "0",
|
"CGO_ENABLED": "0",
|
||||||
},
|
},
|
||||||
commands: [
|
commands: [
|
||||||
'go build -ldflags "-X main.version=${DRONE_TAG##v}" -o release/' + os + "/" + arch + "/ubnt-freifunk-map-api .",
|
'go build -ldflags "-s -w -X main.version=${DRONE_TAG##v}" -trimpath -o release/' + os + "/" + arch + "/ubnt-freifunk-map-api .",
|
||||||
"tar -cvzf release/ubnt-freifunk-map-api_"+ os + "/" + arch + ".tar.gz -C release/" + os + "/" + arch + " ubnt-freifunk-map-api"
|
"tar -cvzf release/ubnt-freifunk-map-api_"+ os + "/" + arch + ".tar.gz -C release/" + os + "/" + arch + " ubnt-freifunk-map-api"
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user