Skip to content

Hosting Full-Stack Application on AWS using elastic beanstalk and AWS CLI. Also, CI/CD pipeline has been set up by integrating GitHub repo with CircleCI

License

Notifications You must be signed in to change notification settings

cynthia3r/hosting-full-stack-application

Repository files navigation

Udagram

The udagram application includes all the major components of a Full-Stack web application and the task was to

  • make the necessary changes in code to connect to the AWS RDS database and S3 storage service
  • deploy and host the application to AWS cloud platform
  • build a seamless CI/CD pipeline which is well documented and maintainable

Getting Started

  1. Clone this repo locally into the location of your choice. GitHub repo
  2. Move the content of the udagram folder at the root of the repository as this will become the main content of the project.
  3. Open a terminal and navigate to the root of the repo
  4. follow the instructions in the installation step

Dependencies

Project dependencies can be found here

Installation

Provision the necessary AWS services needed for running the application:

  1. In AWS, provision a publicly available RDS database running Postgres. postgresql://postgres:postgres@udagram-db.c7cjjx4qtzlu.us-east-1.rds.amazonaws.com:5432/postgres
  2. In AWS, provision a s3 bucket for hosting the uploaded files. http://udagram-frontend-media-bucket.s3-website-us-east-1.amazonaws.com/
  3. Export the ENV variables needed or use a package like dotnev/.
  4. From the root of the repo, navigate udagram-api folder cd starter/udagram-api to install the node_modules npm install. After installation is done start the api in dev mode with npm run dev.
  5. Without closing the terminal in step 1, navigate to the udagram-frontend cd starter/udagram-frontend to intall the node_modules npm install. After installation is done start the api in dev mode with npm run start.

Testing

This project contains two different test suite: unit tests and End-To-End tests(e2e). Follow these steps to run the tests.

  1. cd starter/udagram-frontend
  2. npm run test
  3. npm run e2e

There are no Unit test on the back-end

Unit Tests:

Unit tests are using the Jasmine Framework.

End to End Tests:

The e2e tests are using Protractor and Jasmine.

Infrastructure and Architecture Diagram

Project infrastructure details can be found here

CI/CD Pipeline

Project pipeline process can be found here

AWS and CircleCI Configuration screens and settings

RDS DB Instance EB Backend Server Health Frontend S3 Bucket CircleCI Environment Variables CircleCI GitHub Integration and Deploy Pipeline Udagram Frontend URL

Built With

  • Angular - Single Page Application Framework
  • Node - Javascript Runtime
  • Express - Javascript API Framework

Frontend and backend API URLs

  • Udagram Backend API URL: http://udagramapi-env.eba-apmqumk3.us-east-1.elasticbeanstalk.com/api/v0
  • Udagram Frontend URL: http://udagram-frontend-media-bucket.s3-website-us-east-1.amazonaws.com/

License

License

About

Hosting Full-Stack Application on AWS using elastic beanstalk and AWS CLI. Also, CI/CD pipeline has been set up by integrating GitHub repo with CircleCI

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published