Creating an AWS EC2 Instance
This guide will walk through creating and provisioning an EC2 instance - useful for data collection, automated trading, or running various bots.
Part 1: Creating an Instance
1. Log into the AWS EC2 Console
2. Click "Launch Instance" and select the Ubuntu 20.04 LTS AMI with x86 architecture
3. Choose an Instance Type, select t2.micro to utilize the free tier
4. Configure Instance
5. Select Storage Options
6. Create Security Group
Type
Protocol
Port Range
Source
7. Review Instance and Launch
8. Launch Instance
Part 2: Setting Up Your New Instance
1. Create an Elastic IP (Optional)
A.) Select Elastic IPs from the left hand menu in the EC2 Console. An Elastic IP address is a static IPv4 address designed for dynamic cloud computing.
B.) Click Allocate Instance
C.) Click Actions -> Associate
D.) Write down or remember your Elastic IP address, this is how we will connect to the instance
2. Accessing your Instance via SSH
A.) Open up a terminal / command prompt window and CD to the location where you saved your key-pair.pem file
3. General Provisioning
4. Copying local files to and from your instance
Part 3: Optional Software / Settings
Creating an Ubuntu Service (FastAPI used as an example)
Installing PostgreSQL
Download and install the latest version of Postgres

Restart Postgres
Add Postgres User
Create Database
Installing Redis
Installing Caddy (web server / reverse proxy)
Installing Caddy
Editing Security Group
Type
Protocol
Port Range
Source
Last updated














