I'm trying to verify my site for SEO purposes with Google using https://www.google.com/webmasters/tools/home?hl=en. I am using AWS S3 to host my content, and AWS Cloudfront to serve it through the CDN. I'm following this checklist: http://www.wikihow.com/Get-Your-Website-Indexed-by-Google and am on Step 4.
The steps Google lists to verify are:
- Download this HTML verification file. [googlelongstringofcharacters.html]
- Upload the file to https://www.dynamicdentaledu.com/
- Confirm successful upload by visiting https://www.dynamicdentaledu.com/googlelongstringofcharacters.html in your browser.
- Click Verify below. To stay verified, don't remove the HTML file, even after verification succeeds.
I've added the HTML file to my site's root. When I click confirm in step 3, I get:
So I skipped that and clicked Verify
button in step 4. Google says:
Verification failed for https://www.dynamicdentaledu.com/ using the HTML file method (less than a minute ago). We were unable to connect to your server.
I think this is due to the permissions and bucket policies I have the S3 bucket. They are, respectively:
And
{
"Version": "2008-10-17",
"Statement": [
{
"Sid": "AddPerm",
"Effect": "Allow",
"Principal": {
"AWS": "*"
},
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::dynamicdentaledu.com/*"
}
]
}
How can I enable Google to access what it needs?
EDIT: following AWS's bucket policies, I changed the policy to:
{
"Version": "2008-10-17",
"Statement": [
{
"Sid": "AddPerm",
"Effect": "Allow",
"Principal": "*",
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::dynamicdentaledu.com/*"
}
]
}
Am now getting:
<Error>
<Code>NoSuchKey</Code>
<Message>The specified key does not exist.</Message>
<Key>google*longstringofcharacters*.html</Key>
<RequestId>42DD1F1F0D5E06F7</RequestId>
<HostId>
zbmsLAEMz3ed2zKx3gKCHjrtHxeWmaLl16JJs6012zFcLQdnMH48mFJY1YOETD3WMS/8NwkU3SY=
</HostId>
</Error>