Last active
November 15, 2019 09:58
-
-
Save takenoko-str/6f2d3e095449577e8ddae5cd9677a506 to your computer and use it in GitHub Desktop.
for redhat amazon linux
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 | |
cd /tmp | |
curl https://s3.amazonaws.com/ec2-downloads-windows/SSMAgent/latest/linux_amd64/amazon-ssm-agent.rpm -o amazon-ssm-agent.rpm | |
yum install -y amazon-ssm-agent.rpm | |
tee -a /etc/yum.repos.d/mongodb-org-3.2.repo << EOF | |
[mongodb-org-3.2] | |
name=MongoDB Repository | |
baseurl=https://repo.mongodb.org/yum/amazon/2013.03/mongodb-org/3.2/x86_64/ | |
gpgcheck=1 | |
enabled=1 | |
gpgkey=https://www.mongodb.org/static/pgp/server-3.2.asc | |
EOF | |
tee -a /etc/yum.repos.d/pritunl.repo << EOF | |
[pritunl] | |
name=Pritunl Repository | |
baseurl=https://repo.pritunl.com/stable/yum/centos/7/ | |
gpgcheck=1 | |
enabled=1 | |
EOF | |
gpg --keyserver hkp://keyserver.ubuntu.com --recv-keys 7568D9BB55FF9E5287D586017AE645C0CF8E292A | |
gpg --armor --export 7568D9BB55FF9E5287D586017AE645C0CF8E292A > key.tmp; sudo rpm --import key.tmp; rm -f key.tmp | |
yum -y install pritunl mongodb-org | |
service mongod start | |
start pritunl |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment