+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
You may run a static website using Amazon S3. Individual webpages on a static website contain static material. Additionally, they might include client-side scripting. A dynamic website, on the other hand, is dependent on server-side processing, including server-side scriptings like PHP, JSP, or ASP.NET.
WordPress static site hosting is a good fit for AWS S3. It saves time that would otherwise be spent making sure plugins, themes, and security processes were properly configured and is secure and affordable.
1. Naming Your S3 Bucket
Your bucket name must be www.my-awesome-site.com if your website's domain is www.my-awesome-site.com.
2.2. Setting Up Your S3 Bucket for Static Website Hosting.
Okay, you have your bucket. It has the same name as your domain name, correct? It's time to configure the bucket for static website hosting.
* Navigate to S3 in the AWS Console.
* Click into your bucket.
* Click the “Properties†section.
* Click the “Static website hosting†option.
* Choose "Use this bucket to host a website" .
* Enter “index.html†as the Index document.
3. we need a public access bucket policy. To allow this you must complete the following steps before adding your bucket policy.
* Click into your bucket.
* Choose the "Permissions" tab at the top.
* Under “Public Access Settings†we want to click “Editâ€.* Change to false and save the values for "Block new public bucket policies," "Block public and cross-account access if the bucket has public policies," and "Block new public ACLs and uploading public items."
* Before adding the bucket policy to your static website bucket, you must do this step.
4. Now you must update the Bucket Policy of your bucket to have public read access to anyone in the world. The steps for updating the policy of your bucket in the AWS Console are as follows:
* Navigate to S3 in the AWS Console.
* Click into your bucket.
* Click the “Permissions†section.
* Select “Bucket Policyâ€.
* Add the following Bucket Policy and then Save
Bucket Policy
###################################################################
****************************************************************
{
"Version": "2008-10-17",
"Id": "PolicyForPublicWebsiteContent",
"Statement": [
{
"Sid": "PublicReadGetObject",
"Effect": "Allow",
"Principal": {
"AWS": "*"
},
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::www.my-awesome-site.com/*"
}
]
}
****************************************************************
###################################################################
In Static website hosting
Static website hosting - Enabled
Hosting type - Bucket hosting
Bucket website endpoint - http://first-main.s3-website.ap-south-1.amazonaws.com
Then The S3 Website provides U A Endpoint With This End Point U Access Your Website