This repository has been archived by the owner on Aug 19, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
AWS Deployment
Sabien edited this page Jan 29, 2020
·
33 revisions
This is a guide to deploy our vapor instance to AWS for making the CI/CD pipeline streamlined.
Steps
- Create AWS account
- Select free tier
- Sign into console
- Choose AMI:
- Ubuntu Server 16.04 LTS (HVM), SSD Volume Type
- Choose the 64-bit (x86) option
- Instance Type:
- Choose the t2.micro Instance Type
- Configure Instance
- Default settings
- Add Storage
- Chance Size to: 20 GiB
- Add Tags
- Default settings (no tags)
- Configure Security Groups
- Add a rule: override the default ssh with "myIP/32"
- Review
- Just launch the instance
-
Tags Create a new key pair and name it "username-desktop"
-
Add billing alerts
sudo su
apt-get update && apt-get upgrade -y && apt-get dist-upgrade -y && apt-get install htop -y
apt-get install unattended-upgrades -y && dpkg-reconfigure -plow unattended-upgrades
apt-get install ntp -y && ntpq -p && service ntp restart
reboot
sudo apt-get install clang libicu-dev libcurl4-openssl-dev lldb git wget unzip -y
sudo apt-get install swift vapor
echo "export PATH=/swift-4.2/usr/bin:\"\${PATH}\"" >> ~/.bashrc
source ~/.bashrc
- clone olWebsite to ~/
- run our custom deploy
References:
- prereqs: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/connection-prereqs.html
- setup putty: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/putty.html\
- vapor guide: https://medium.com/swiftybeaver-blog/deployment-of-a-vapor-app-to-aws-ec2-f577eaa6c38c
- vapor install: https://docs.vapor.codes/3.0/install/ubuntu/
- vapor + react: https://www.vaporforums.io/viewThread/25