简体   繁体   English

在 S3 存储桶文件夹中托管静态网站

[英]Hosting a Static website in S3 Bucket Folder

I am trying to host static websites on S3.我正在尝试在 S3 上托管静态网站。 I know how to do it using S3 buckets ( Link )我知道如何使用 S3 存储桶( 链接

Question:题:

Can I do it using S3 folder instead of S3 bucket?我可以使用 S3 文件夹而不是 S3 存储桶吗? So that I don't have to create a new bucket when I want to host a static site and simply host it by creating a new folder in the same bucket.因此,当我想托管静态站点时不必创建新存储桶,只需在同一个存储桶中创建一个新文件夹即可托管它。

If you want to point a custom domain name to the site you are hosting in S3, then the bucket name must match the domain name, so you can't have multiple sites with multiple domains in the same bucket.如果您想将自定义域名指向您在 S3 中托管的站点,则存储桶名称必须与域名匹配,因此您不能在同一个存储桶中拥有多个站点和多个域。 Also, the static site hosting settings are at the bucket level not the "folder" level.此外,静态站点托管设置位于存储桶级别而不是“文件夹”级别。 NOTE: There is actually no such thing as a folder in S3, just key prefixes.注意: S3 中实际上没有文件夹这样的东西,只有键前缀。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 用于静态网站托管的S3 Bucket Endpoint - S3 Bucket Endpoint for Static Website Hosting 托管静态网站时如何将 AWS S3 存储桶长 URL 更改为短 S3 URL? - How to change AWS S3 bucket long URL to short S3 URL when hosting a static website? 静态网站托管中针对子域的AWS S3存储桶重定向与DNS CNAME - AWS S3 bucket redirect vs DNS CNAME for subdomain in static website hosting s3权限是什么,它允许用户有权为静态网站托管启用存储桶? - What is the s3 permission to allow the user the rights to enable the bucket for static website hosting? 如果我为 static 网站托管配置了一个 s3 存储桶,那么我可以通过 API 将资产上传到它吗? - If I configure a s3 bucket for static website hosting, then can I upload assets to it through API? S3策略,允许用户启用/禁用特定存储桶上的版本控制以及启用/禁用静态网站托管 - S3 policy to allow a user to enable / disable versioning on a specific bucket AND enable / disable static website hosting AWS S3 Static 网站托管上的路由规则 - RoutingRules on AWS S3 Static website hosting 托管静态网站的 S3 存储桶策略 - S3 Bucket Policy for Hosted Static Website 带 SSL 和静态网站的 S3 存储桶 - S3 bucket with SSL with static website 在AWS S3上的特定文件夹中托管的网站 - Website hosting in specific folder on AWS S3
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM