I want to know how to avoid indexing files in the Amazon S3 bucket.

Asked 2 years ago, Updated 2 years ago, 132 views

What do you want to solve

Save images and video files to Amazon S3.

This file is made public, and only those who want to show it can view it by providing the URL.

Looking at various information, I saw information that if you make it public, it will be indexed by crawlers and it will be a hit by some kind of search.

I want to keep it public and not display it in my browser's search results.

Problems/errors encountered

I know that placing the following files in the root domain can avoid crawler patrols, but if I put them at the top of the bucket, will the image files in my bucket not be indexed?

robots.txt

User-agent:*
Disallow :/

Instead of retrieving a domain and putting an image file in it, it's just saving the file in the S3 bucket.

Thank you for your cooperation.

aws amazon-s3

2022-09-30 20:16

2 Answers

As a general rule, the public URL of the object is public and should not be indexed unless it is found as a crawler, but it is probably assumed that the URL is shared again.

As far as I'm concerned, I think most cases will be fine by listing them on robots.txt.However, there are possible exceptions.

  • If you use a deprecated (non-domain-based) path-based URL, it doesn't make sense. (Normally, it shouldn't happen without a lot of things.)

If you do not simply want to be indexed or should not be displayed to anyone other than yourself, there are several possible measures.


2022-09-30 20:16

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.