Log in to your AWS console by entering your credentials
Check npm and node installed or not
npm -v
node -v
Creating a react app
Run the following Commands
npm create vite@latest
cd Dharshinisrig
npm install
npm run dev
Follow the link to see the react app
The React App should run and the output should look like
Open the React App and Edit the App.tsx with your informations
Run the command -> npm run build
Create a S3 Bucket in the Aws console
Remove Block all Public access
Enable Bucket Versioning & Add Tags according to needs
Enable Static Web Hosting In Properties of the Bucket
Edit the Bucket Policy in Permissions of the Bucket
Copy Bucket ARN
Generate Bucket Policy & Save Changes
Upload all the Files and Folders in the dist folder in the React App to the S3 bucket
Copy the URL of the index.html file
Or Copy the Bucket Endpoint and Run in the browser
Link - http://714022205024-dharshinisrig.s3-website-us-east-1.amazonaws.com
CloudFront
Create Distribution
WAF Disable
Create Distribution & Deploy using CloudFront
Copy Distribution Domain name
URL - https://d2yop5uofve2kk.cloudfront.net
Run URL in the browser
*Delete CloudFront *
Delete Objects in S3
Delete S3 Bucket
Top comments (0)