Skip to content

Instantly share code, notes, and snippets.

@serkanh
Created October 28, 2015 19:08
Show Gist options
  • Save serkanh/cc3bb4dae101cb9aeff9 to your computer and use it in GitHub Desktop.
Save serkanh/cc3bb4dae101cb9aeff9 to your computer and use it in GitHub Desktop.
description "Vault server"
start on runlevel [2345]
stop on runlevel [!2345]
respawn
chdir /home/vault
env VAULT_ADDR=http://127.0.0.1:8200
script
if [ -f "/etc/service/vault" ]; then
. /etc/service/vault
fi
# Make sure to use all our CPUs, because Vault can block a scheduler thread
export GOMAXPROCS=`nproc`
exec /usr/local/bin/vault server \
-config="/home/vault/.vault-config/vault.hcl" \
\$${VAULT_FLAGS} \
>>/var/log/vault.log 2>&1
end script
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment