重写Amazon S3的静态URL [英] Rewriting Amazon S3 static urls

查看:471
本文介绍了重写Amazon S3的静态URL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在亚马逊S3托管纯静态网站的利益,是重写用于通过重写引擎访问它的资源,更友好的方式,URL和端点的唯一途径,如任何Web服务器?并且将它最好的主办这是一个EC2?

In the interest of hosting purely static sites from Amazon S3, is the only route to rewrite the URLs and endpoints for accessing it's resources in a friendlier way via a rewrite engine such as any web server? And would it best to host this as an EC2?

这似乎矫枉过正,但不知道是否有替代品。

It seems overkill but wasn't sure if there were alternatives.

推荐答案

我不知道为什么你需要重写。

I'm not sure why you need to rewrite.

您可以指定一个DNS CNAME到S3桶DNS。他们最近开始支持默认文档。

You can assign a DNS CNAME to an S3 bucket for DNS. And they recently started supporting a default document.

所以,你可以完美承载 http://www.example.com/ 或的 http://www.example.com/some/path/to/some/file.html

So you can perfectly host http://www.example.com/ or http://www.example.com/some/path/to/some/file.html

的http:// aws.typepad.com/aws/2011/02/host-your-static-website-on-amazon-s3.html

这篇关于重写Amazon S3的静态URL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆