terraform-digitalocean-spoke/spoke-app-run

17 lines
271 B
Plaintext
Raw Permalink Normal View History

2020-02-10 03:28:45 +00:00
#!/usr/bin/env bash
set -o errexit
set -o pipefail
main() {
cd /home/spoke/app
2020-03-05 01:46:02 +00:00
# shellcheck source=/dev/null
2020-02-10 03:28:45 +00:00
source ~/.nvm/nvm.sh
nvm use
if [[ -f ./build/server/server/index.js ]]; then
exec node ./build/server/server
fi
2020-02-10 03:28:45 +00:00
exec npm start
}
main "${@}"