s3 static hosting display a list of the folder contents instead of index.html

I host a small page on s3 : http://artisants.maison-travaux.fr.s3-website-eu-west-1.amazonaws.com/

There is a domain name with a CNAME pointing on that bucket. When I go to the index.html url : http://artisants.maison-travaux.fr/index.html It works.

But the root of the bucket display a list of the bucket contents : http://artisants.maison-travaux.fr/

In the bucket configuration, I did add index.html as the index document. But it does not do the trick. Do I have to edit some redirection rule ?

It seems weird to me that it's not the default configuration.

I tried a redirect rule :

<RoutingRules>
    <RoutingRule>
        <Redirect>
            <Protocol>http</Protocol>
            <ReplaceKeyWith>index.html</ReplaceKeyWith>
            <HttpRedirectCode>301</HttpRedirectCode>
        </Redirect>
    </RoutingRule>
</RoutingRules>

That seems to have zero effect.


So, it appears that it's not really doable.

The people in charge of managing the DNS have to make the CNAME point on the correct endpoint.

链接地址: http://www.djcxy.com/p/70218.html

上一篇: 收到我的AWS账户的S3存储桶安全通知电子邮件?

下一篇: s3静态托管显示文件夹内容的列表,而不是index.html