Last active
November 15, 2017 14:04
-
-
Save bernard-wagner/11888223da126f208c7c52e3f8bd8384 to your computer and use it in GitHub Desktop.
Alpine - Hashicorp Vault
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
export GOROOT=/usr/lib/go/ | |
export GOPATH=/root/go | |
export VAULT_SRC_PATH=$GOPATH/src/github.com/hashicorp/vault | |
export PATH=$PATH:$GOPATH/bin | |
apk add --update --repository http://dl-cdn.alpinelinux.org/alpine/edge/main musl-dev make git bash | |
apk add --update --repository http://dl-cdn.alpinelinux.org/alpine/edge/community go | |
mkdir -p $GOPATH | |
git clone https://github.com/hashicorp/vault $VAULT_SRC_PATH | |
cd $VAULT_SRC_PATH | |
make bootstrap && make | |
# Install vault to /usr/loca/bin | |
cp $GOPATH/bin/vault /usr/local/bin/vault | |
apk del go make git | |
# Clean directories | |
cd /root | |
rm -rf $GOPATH /usr/share/man /tmp/* /var/cache/apk/* |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment