-
Notifications
You must be signed in to change notification settings - Fork 1
AWS Setup
Siqi Tian edited this page Feb 5, 2017
·
4 revisions
The server is an EC2 instance with ELB at AWS. Essential setup is listed as below:
- EC2 instance with Ubuntu 16.04.x LTS. EBS drive is mount to
/dev/sda1
. - Use the following Security Groups: HTTP & SSH (opens port 80 and port 22), HTTPS (opens port 443).
- Submit SSL Certificate through
aws iam
. See here. Use the SSL Certificate for 443 forwarding protocol. - Add instance to ELB, configure with port forwarding 80 to 80, 443 to 443. Use same Security Groups as EC2.
- Set ELB Health Check to address HTTPS:443/ping_test/, with interval 180 s and timeout 15 s.
- Set ELB Monitoring Alarm for Healthy Host < 1 sending email to
daslab
Gmail.
Once done, you can access the server via ssh
. Use the server's Public IP address, instead of Private IP. AWS EC2 are configured to use a certificate for authentication, not password (In fact, user ubuntu has no password). Use -i
to supply the certificate.
When the server's Django or Apache malfunctions, you should receive an alert email forwarded from daslab
Gmail. After fixing the issue, you may need to reset the ELB Health Check to force instant recheck (e.g. set interval to 300 s and then back to 180 s).
New Admin Setup
Admin Responsibility
Server Environment
Overview
Linux
Python