Skip to content

nuanv/CRC-AWS

Repository files navigation

AWS Cloud Resume Challenge

This repository contains the code for the Cloud Resume Challenge project using AWS.

Architecture

Running the project

  1. Clone the repository.
git clone https://github.com/nuanv/cloud-resume-project.git
cd cloud-resume-project
  1. Copy the example terraform var file example_terraform.tfvars to terraform.tfvars.
cp example_terraform.tfvars terraform.tfvars

Note

Install terraform and aws-cli before proceeding further.
Run aws configure and provide required credentials for the user account.
Change the variables in terraform.tfvars according to your preference.

  1. Initialize a working directory containing config files and install plugins for required providers.
terraform init

Warning

While the terraform deployment allows you to choose region of your choice, make sure you change the region in modules/function/function.ts to the region of your choice.

  1. Now we will run our function module which will setup the API gateway, Lambda function and DynamoDB.
terraform apply -target=module.function
  1. Once the infrastructure is deployed you will receive api invoke URL in your terminal. Change the url in src/app/api/getViews.ts to the url you received.
const API_URL = '<API Gateway Invoke URL>';
  1. Install required packages & Build static files for our website.
npm install
npm run export
  1. Now we will run our website module which will setup the S3 bucket and cloudflare DNS.
terraform apply -target=module.website
  1. To bring down the whole infrastructure run.
terraform destroy

Visit your domain to update view count

Count

About

The Cloud Resume Challenge

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published