TIA ETL Pipeline
A ETL pipeline that extract Flight data from Tribhuvan International Airport.
Architecture

Data is extracted from tia
Load to s3
Transform the data
Load the data in RDS
Dashboard

How to use?
Set the values inside
.env and terraform/variables.tfcd terraformterraform init .terraform applyNow you can see
ec2 ip and rds endpoint in terminalterraform output private_key and copy the rsa key into tia_key.pem in project root directorycd ..chmod 400 tia_key.pemConnect to the ec2 instance using
ssh -i tia_key.pem {user_name}@{ec2_ip} sudo snap install docker to install docker in ec2Username and password used by airflow and local postgres server are hardcoded in
docker-compose.yamlCopy all files and folders to ec2 except terraform
docker-compose builddocker-compose upNow docker container will run and data will be extracted every 30 minutes and stored in RDS.
To stop
docker-compose downTo remove all the services in aws
terrafrom destroyWhy this architecture?
I used docker and ec2 in this pipeline to learn about them. One can simply run this pipeline by removing docker and airflow in lambda. Using lambda will be quick and cost effictive.
0 likes · 17 views · Feb 28, 2024
Contribute to anuj66283/tia-etl development by creating an account on GitHub.