You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
29 lines
732 B
29 lines
732 B
# Clone Debian Stretch template, set up IPs, hostname, ssh keys
|
|
apt update
|
|
apt -y dist-upgrade
|
|
|
|
# Install mongodb
|
|
# Install deps
|
|
apt-get -y install dirmngr
|
|
|
|
# XXX note, this isn't latest release (4.0)
|
|
apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 2930ADAE8CAF5059EE73BB4B58712A2291FA4AD5
|
|
echo "deb http://repo.mongodb.org/apt/debian stretch/mongodb-org/3.6 main" | tee /etc/apt/sources.list.d/mongodb-org-3.6.list
|
|
apt-get update
|
|
apt-get install -y mongodb-org
|
|
|
|
# Set to bind to IP, edit /etc/mongod.conf
|
|
bindIp: 10.22.22.119
|
|
|
|
systemctl daemon-reload
|
|
systemctl enable mongod.service
|
|
systemctl restart mongod.service
|
|
|
|
# Open up firewall:
|
|
-A INPUT -p tcp --dport 27017 -j ACCEPT
|
|
|
|
|
|
### XXX Backups
|
|
### XXX Prometheus :)
|
|
|