Last active
October 17, 2017 01:21
-
-
Save mince27/7e11a7f0915fd9abc08dd44245d8a372 to your computer and use it in GitHub Desktop.
User Data file for configuring a Lightsail instance
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/bash | |
readonly APP_HOME='/opt' | |
readonly NODE_SRC='https://rpm.nodesource.com/setup_6.x' | |
readonly SOURCE_REPO='https://github.com/stelligent/chat-app' | |
yum update -y | |
yum install -y git | |
echo 'Installing node' | |
curl --silent --location "$NODE_SRC" | bash - | |
yum install nodejs -y | |
echo "Cloning $SOURCE_REPO in $APP_HOME" | |
cd "$APP_HOME" || exit 1 | |
git clone "$SOURCE_REPO" | |
cd 'chat-app' || exit 1 | |
npm install --no-optional | |
npm run start |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment