-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
2 additions
and
51 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,55 +3,14 @@ ssh_authorized_keys: | |
- %(LOCAL_SSH_KEY)s | ||
bootcmd: | ||
- set -ex | ||
- cloud-init-per once fallocate-swapfile fallocate -l 4G /swapfile | ||
- cloud-init-per once chmod-swapfile chmod 600 /swapfile | ||
- cloud-init-per once mkswap-swapfile mkswap /swapfile | ||
- cloud-init-per once curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash - | ||
package_upgrade: true | ||
packages: | ||
- apache2 | ||
- awscli | ||
- libarchive-tools | ||
- build-essential | ||
- git | ||
- graphviz | ||
- libapache2-mod-wsgi-py3 | ||
- libcurl4-gnutls-dev | ||
- libevent-dev | ||
- libfreetype6-dev | ||
- libjpeg-dev | ||
- liblcms2-dev | ||
- libmagic-dev | ||
- libpq-dev | ||
- libssl-dev | ||
- libtiff5-dev | ||
- libwebp-dev | ||
- libxml2-dev | ||
- libxslt1-dev | ||
- lzop | ||
- nodejs | ||
- npm | ||
- ntp | ||
- pv | ||
- python2.7-dev | ||
- python3-dev | ||
- python3-pip | ||
- software-properties-common | ||
- python3-virtualenv | ||
- ruby-dev | ||
- unattended-upgrades | ||
- update-notifier-common | ||
- zlib1g-dev | ||
- libffi-dev | ||
- bsd-mailx | ||
- echo "Booting" | ||
power_state: | ||
mode: reboot | ||
output: | ||
all: '| tee -a /var/log/cloud-init-output.log' | ||
runcmd: | ||
- sudo -u ubuntu mv /home/ubuntu/.ssh/authorized_keys /home/ubuntu/.ssh/authorized_keys2 | ||
- sudo -u ubuntu aws s3 cp --region=us-west-2 %(S3_AUTH_KEYS)s /home/ubuntu/.ssh/authorized_keys | ||
# Manually install java | ||
- sudo -u ubuntu mkdir /home/ubuntu/.aws | ||
- sudo -u ubuntu aws s3 cp --region=us-west-2 s3://regulome-conf-prod/.aws-regulome/credentials ~ubuntu/.aws | ||
- sudo -u ubuntu rm -r /home/ubuntu/.aws | ||
|
@@ -84,13 +43,6 @@ runcmd: | |
- a2disconf localized-error-pages | ||
- a2disconf other-vhosts-access-log | ||
- a2disconf serve-cgi-bin | ||
- sudo sed -i -e 's/inet_interfaces = all/inet_interfaces = loopback-only/g' /etc/postfix/main.cf | ||
- PUBLIC_DNS_NAME="$(curl http://169.254.169.254/latest/meta-data/public-hostname)" | ||
- sudo sed -i "/myhostname/c\myhostname = $PUBLIC_DNS_NAME" /etc/postfix/main.cf | ||
- sudo echo "127.0.0.0 $PUBLIC_DNS_NAME" | sudo tee --append /etc/hosts | ||
- sudo mv /etc/mailname /etc/mailname.OLD | ||
- sudo echo "$PUBLIC_DNS_NAME" | sudo tee --append /etc/mailname | ||
- sudo service postfix restart | ||
users: | ||
- default | ||
- name: build | ||
|
@@ -112,7 +64,6 @@ write_files: | |
Unattended-Upgrade::Allowed-Origins { | ||
"${distro_id} ${distro_codename}-security"; | ||
}; | ||
Unattended-Upgrade::Mail "[email protected]"; | ||
Unattended-Upgrade::Automatic-Reboot "false"; | ||
- path: /etc/cron.d/cloudwatchmon | ||
content: | | ||
|
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