DockerCLI/scripts/build/linux-cross

22 lines
369 B
Bash
Executable File

#!/usr/bin/env bash
#
# Build static linux binary for multiple architectures
#
set -eu -o pipefail
source ./scripts/build/.variables
CROSS_OSARCH="linux/amd64 linux/arm"
# Compile is broken
# linux/ppc64le
# Not yet supported by gox
# linux/s390x
gox -output build/docker-{{.OS}}-{{.Arch}} \
-osarch "${CROSS_OSARCH}" \
--ldflags "${LDFLAGS}" \
"${SOURCE}"