在nginx中提供远程文件

我在Azure中有一个存储帐户。 我有一个容器,我想通过nginx服务的文件。

例如,我得到了位于https://blabla.blob.core.windows.net/dist/index.htmlhttps://blabla.blob.core.windows.net/dist/app.cssindex.htmlapp.css https://blabla.blob.core.windows.net/dist/app.css

我有一个服务器安装程序在'10.0.0.1'上使用nginx进行收听。

当我尝试达到10.0.0.1我希望nginx抓取位于远程存储帐户中的文件。 这是我试图没有成功的:

 server { listen 80; keepalive_timeout 5; root https://blabla.blob.core.windows.net/dist; .... location / { try_files $uri /index.html; } } 

不幸的是,我收到来自nginx的以下错误消息:

 2016/01/04 11:37:59 [error] 2192#0: *13 rewrite or internal redirection cycle while internally redirecting to "/index.html", client: 10.0.0.10, server: , request: "GET / HTTP/1.1", host: "my-machine-1" 

你可能需要这样的东西

 server { listen 80; keepalive_timeout 5; root /var/www/html; location / { proxy_pass https://blabla.blob.core.windows.net/dist/ }