Last active
April 12, 2019 01:24
-
-
Save jeongukjae/d0c89ef4a5859d4fec6a48a67212caeb to your computer and use it in GitHub Desktop.
aws user data to install codedeploy agent, docker and docker compose (ap-northeast-2)
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 | |
# install code deploy agent | |
yum -y update | |
yum install -y ruby | |
cd /home/ec2-user | |
curl -O https://aws-codedeploy-ap-northeast-2.s3.amazonaws.com/latest/install | |
chmod +x ./install | |
./install auto | |
# install docker | |
amazon-linux-extras install -y docker | |
service docker start | |
usermod -a -G docker ec2-user | |
# install docker compose | |
curl -L https://github.com/docker/compose/releases/download/1.24.0/docker-compose-`uname -s`-`uname -m` -o /usr/local/bin/docker-compose | |
chmod +x /usr/local/bin/docker-compose |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment