feat: Add multi-platform build support for Linux binaries and Dockerfiles
Some checks failed
continuous-integration/drone/push Build is failing
Some checks failed
continuous-integration/drone/push Build is failing
This commit is contained in:
43
.drone.yml
43
.drone.yml
@@ -33,6 +33,19 @@ steps:
|
||||
commands:
|
||||
- CGO_ENABLED=0 go build -v ./cmd/invertergui
|
||||
|
||||
- name: build-linux-binaries
|
||||
image: cache.coadcorp.com/library/golang:1.26
|
||||
environment:
|
||||
GOFLAGS: -mod=mod
|
||||
commands:
|
||||
- mkdir -p dist
|
||||
- CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -v -o dist/invertergui-linux-amd64 ./cmd/invertergui
|
||||
- CGO_ENABLED=0 GOOS=linux GOARCH=arm64 go build -v -o dist/invertergui-linux-arm64 ./cmd/invertergui
|
||||
when:
|
||||
event:
|
||||
- push
|
||||
- tag
|
||||
|
||||
- name: docker-build-validate
|
||||
image: gcr.io/kaniko-project/executor:v1.24.0
|
||||
commands:
|
||||
@@ -46,11 +59,8 @@ steps:
|
||||
settings:
|
||||
registry: registry.coadcorp.com
|
||||
repo: "registry.coadcorp.com/nathan/invertergui"
|
||||
dockerfile: Dockerfile
|
||||
dockerfile: Dockerfile.publish.amd64
|
||||
platform: "linux/amd64"
|
||||
build_args:
|
||||
- TARGETOS=linux
|
||||
- TARGETARCH=amd64
|
||||
username: nathan
|
||||
password:
|
||||
from_secret: registry_password
|
||||
@@ -65,11 +75,8 @@ steps:
|
||||
settings:
|
||||
registry: registry.coadcorp.com
|
||||
repo: "registry.coadcorp.com/nathan/invertergui"
|
||||
dockerfile: Dockerfile
|
||||
dockerfile: Dockerfile.publish.arm64
|
||||
platform: "linux/arm64"
|
||||
build_args:
|
||||
- TARGETOS=linux
|
||||
- TARGETARCH=arm64
|
||||
username: nathan
|
||||
password:
|
||||
from_secret: registry_password
|
||||
@@ -100,11 +107,8 @@ steps:
|
||||
settings:
|
||||
registry: registry.coadcorp.com
|
||||
repo: "registry.coadcorp.com/nathan/invertergui"
|
||||
dockerfile: Dockerfile
|
||||
dockerfile: Dockerfile.publish.amd64
|
||||
platform: "linux/amd64"
|
||||
build_args:
|
||||
- TARGETOS=linux
|
||||
- TARGETARCH=amd64
|
||||
username: nathan
|
||||
password:
|
||||
from_secret: registry_password
|
||||
@@ -122,11 +126,8 @@ steps:
|
||||
settings:
|
||||
registry: registry.coadcorp.com
|
||||
repo: "registry.coadcorp.com/nathan/invertergui"
|
||||
dockerfile: Dockerfile
|
||||
dockerfile: Dockerfile.publish.arm64
|
||||
platform: "linux/arm64"
|
||||
build_args:
|
||||
- TARGETOS=linux
|
||||
- TARGETARCH=arm64
|
||||
username: nathan
|
||||
password:
|
||||
from_secret: registry_password
|
||||
@@ -163,11 +164,8 @@ steps:
|
||||
settings:
|
||||
registry: registry.coadcorp.com
|
||||
repo: "registry.coadcorp.com/nathan/invertergui"
|
||||
dockerfile: Dockerfile
|
||||
dockerfile: Dockerfile.publish.amd64
|
||||
platform: "linux/amd64"
|
||||
build_args:
|
||||
- TARGETOS=linux
|
||||
- TARGETARCH=amd64
|
||||
username: nathan
|
||||
password:
|
||||
from_secret: registry_password
|
||||
@@ -182,11 +180,8 @@ steps:
|
||||
settings:
|
||||
registry: registry.coadcorp.com
|
||||
repo: "registry.coadcorp.com/nathan/invertergui"
|
||||
dockerfile: Dockerfile
|
||||
dockerfile: Dockerfile.publish.arm64
|
||||
platform: "linux/arm64"
|
||||
build_args:
|
||||
- TARGETOS=linux
|
||||
- TARGETARCH=arm64
|
||||
username: nathan
|
||||
password:
|
||||
from_secret: registry_password
|
||||
|
||||
Reference in New Issue
Block a user