mirror of https://github.com/dexidp/dex.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
493 B
27 lines
493 B
#!/bin/bash -e |
|
|
|
GOARCH=amd64 |
|
OSS=( "darwin" "linux" ) |
|
|
|
|
|
source ./env |
|
|
|
# cannot cross compile when GOBIN is set. |
|
# See: |
|
# https://golang.org/issue/9769 |
|
# https://golang.org/issue/11778 |
|
unset GOBIN |
|
|
|
for GOOS in ${OSS[@]}; do |
|
name=dex-$VERSION-$GOOS-$GOARCH |
|
|
|
rm -fr $name.tar.gz $name/ |
|
mkdir $name |
|
|
|
GOOS=$GOOS GOARCH=$GOARCH go build -o $name/dexctl -ldflags="$LD_FLAGS" github.com/coreos/dex/cmd/dexctl |
|
|
|
tar -czf $name.tar.gz $name/ |
|
echo "Created ${name}.tar.gz" |
|
|
|
rm -fr $name/ |
|
done
|
|
|