Last active
June 16, 2021 00:18
-
-
Save interwebologist/ed917afce0f655363a57a22c34e59eaf to your computer and use it in GitHub Desktop.
terraform-startup-script
This file contains hidden or 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 | |
sudo apt-get update | |
sudo apt-get install -y apt-transport-https ca-certificates gnupg lsb-release | |
curl -fsSL https://download.docker.com/linux/debian/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg | |
echo "deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/debian $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null | |
sudo apt-get update | |
sudo apt-get install -yq docker-ce docker-ce-cli containerd.io | |
docker run -p 80:8000 -d --restart always -e DATABASE_USERNAME=$1 -e DATABASE_PASSWORD=$2 -e DATABASE_HOST=$3 ispeakcomputer/interview:latest |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
install docker and run app