mirror of
https://github.com/mentos1386/zdravko.git
synced 2024-11-22 15:53:45 +00:00
22 lines
464 B
Makefile
22 lines
464 B
Makefile
# Build the application
|
|
build: build-bin build-docker
|
|
|
|
# Build multiarch binaries
|
|
build-bin:
|
|
#!/bin/bash
|
|
for os in {{OS}}
|
|
do
|
|
for arch in {{ARCH}}
|
|
do
|
|
echo "Building zdravko for $os $arch..."
|
|
CGO_ENABLED=0 GOOS=$os GOARCH=$arch go build -o bin/zdravko-$os-$arch cmd/zdravko/main.go
|
|
done
|
|
done
|
|
|
|
# Build docker image
|
|
build-docker: build-bin
|
|
#!/bin/bash
|
|
docker buildx build \
|
|
-f build/Dockerfile \
|
|
-t {{DOCKER_IMAGE}} \
|
|
.
|