mirror of https://github.com/statping/statping
building
parent
8c11f873cf
commit
5d071d8e6b
11
README.md
11
README.md
|
@ -37,13 +37,13 @@ LETSENCRYPT_HOST=mydomain.com \
|
||||||
```
|
```
|
||||||
Once your instance has started, it will take a moment to get your SSL certificate. Make sure you have a A or CNAME record on your domain that points to the IP/DNS of your server running Statup.
|
Once your instance has started, it will take a moment to get your SSL certificate. Make sure you have a A or CNAME record on your domain that points to the IP/DNS of your server running Statup.
|
||||||
|
|
||||||
## Run on AWS EC2
|
## Run on EC2 Server
|
||||||
Running Statup on the smallest EC2 server is very quick using the AWS AMI Image: `ami-84da93fc`.
|
Running Statup on the smallest EC2 server is very quick using the AWS AMI Image: `ami-84da93fc`.
|
||||||
```bash
|
```bash
|
||||||
ec2-run-instances --key KEYPAIR ami-84da93fc
|
ec2-run-instances --key KEYPAIR ami-7ad39a02
|
||||||
```
|
```
|
||||||
|
|
||||||
# EC2 with SSL Certificate
|
# EC2 with Automatic SSL Certificate
|
||||||
```bash
|
```bash
|
||||||
wget https://raw.githubusercontent.com/hunterlong/statup/master/servers/ec2-ssl.sh
|
wget https://raw.githubusercontent.com/hunterlong/statup/master/servers/ec2-ssl.sh
|
||||||
#
|
#
|
||||||
|
@ -51,12 +51,9 @@ wget https://raw.githubusercontent.com/hunterlong/statup/master/servers/ec2-ssl.
|
||||||
#
|
#
|
||||||
# nano ec2-ssl.sh
|
# nano ec2-ssl.sh
|
||||||
#
|
#
|
||||||
ec2-run-instances --key KEYPAIR \
|
ec2-run-instances --key KEYPAIR --user-data-file ec2-ssl.sh ami-7ad39a02
|
||||||
--user-data-file ec2-ssl.sh \
|
|
||||||
ami-bf5eb9d6
|
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
## Email Nofitications
|
## Email Nofitications
|
||||||
Statup includes email notification via SMTP if your services go offline.
|
Statup includes email notification via SMTP if your services go offline.
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
exec > >(tee /var/log/user-data.log|logger -t user-data -s 2>/dev/console) 2>&1
|
|
||||||
|
|
||||||
## Domain for new SSL certificate
|
## Domain for new SSL certificate
|
||||||
LETSENCRYPT_HOST="status.balancebadge.io"
|
LETSENCRYPT_HOST="status.balancebadge.io"
|
||||||
|
@ -11,6 +10,7 @@ LETSENCRYPT_EMAIL="info@socialeck.com"
|
||||||
############# Leave this part alone ###############
|
############# Leave this part alone ###############
|
||||||
###################################################
|
###################################################
|
||||||
|
|
||||||
|
exec > >(tee /var/log/user-data.log|logger -t user-data -s 2>/dev/console) 2>&1
|
||||||
printf "Statup will try to create an SSL for domain: $LETSENCRYPT_HOST\n"
|
printf "Statup will try to create an SSL for domain: $LETSENCRYPT_HOST\n"
|
||||||
printf "\nexport LETSENCRYPT_HOST=$LETSENCRYPT_HOST\n" >> /home/ubuntu/.profile
|
printf "\nexport LETSENCRYPT_HOST=$LETSENCRYPT_HOST\n" >> /home/ubuntu/.profile
|
||||||
printf "export LETSENCRYPT_EMAIL=$LETSENCRYPT_EMAIL\n" >> /home/ubuntu/.profile
|
printf "export LETSENCRYPT_EMAIL=$LETSENCRYPT_EMAIL\n" >> /home/ubuntu/.profile
|
||||||
|
|
|
@ -46,10 +46,13 @@ fi
|
||||||
sudo docker system prune -af
|
sudo docker system prune -af
|
||||||
|
|
||||||
logger "Status Process complete. IP: $EC_IP | DNS: $EC2_ENDPOINT\n"
|
logger "Status Process complete. IP: $EC_IP | DNS: $EC2_ENDPOINT\n"
|
||||||
|
printf "Status Process complete. IP: $EC_IP | DNS: $EC2_ENDPOINT\n"
|
||||||
|
|
||||||
|
# commands to reverse installation and only leave init.sh
|
||||||
#sudo docker rm -f $(sudo docker ps -a -q)
|
#sudo docker rm -f $(sudo docker ps -a -q)
|
||||||
#sudo docker rmi $(sudo docker images -q)
|
#sudo docker rmi $(sudo docker images -q)
|
||||||
#rm -rf docker-compose.yml
|
#rm -rf docker-compose.yml
|
||||||
#sudo rm -rf statup
|
#sudo rm -rf statup
|
||||||
#sudo rm startup.sh
|
#sudo rm startup.sh
|
||||||
|
#sudo docker system prune -af
|
||||||
#sudo service docker stop
|
#sudo service docker stop
|
||||||
|
|
Loading…
Reference in New Issue