sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
- Download zsh-autosuggestions by
| wget https://github.com/prometheus/node_exporter/releases/download/v1.5.0/node_exporter-1.5.0.linux-amd64.tar.gz | |
| tar xvzf node_exporter-*.tar.gz | |
| mv node_exporter-*/node_exporter /usr/local/bin/ | |
| # Create a node_exporter user | |
| useradd --no-create-home --shell /bin/false node_exporter | |
| # Set the ownership of the node_exporter binary to the node_exporter user |
| echo "instance id: $1" | |
| echo "instance type: $2" | |
| #2>&1 > /dev/null to suppress the cli output | |
| echo "stopping instance" | |
| aws ec2 stop-instances --instance-ids $1 2>&1 > /dev/null | |
| echo "waiting for instance to stop" | |
| aws ec2 wait instance-stopped --instance-ids $1 |
| files: | |
| "/etc/nginx/conf.d/00_elastic_beanstalk_proxy.conf": | |
| mode: "000755" | |
| owner: root | |
| group: root | |
| content: | | |
| server { | |
| listen 80; | |
| gzip on; |
| <!doctype html> | |
| <title>Site Maintenance</title> | |
| <style> | |
| body { text-align: center; padding: 150px; } | |
| h1 { font-size: 50px; } | |
| body { font: 20px Helvetica, sans-serif; color: #333; } | |
| article { display: block; text-align: left; width: 650px; margin: 0 auto; } | |
| a { color: #dc8100; text-decoration: none; } | |
| a:hover { color: #333; text-decoration: none; } | |
| </style> |