Skip to content

Instantly share code, notes, and snippets.

@shapeshed
Created November 11, 2015 09:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shapeshed/0bff69546ae312899d51 to your computer and use it in GitHub Desktop.
Save shapeshed/0bff69546ae312899d51 to your computer and use it in GitHub Desktop.
S3 Hosted Site custom domain proxy
server {
listen 80;
server_name some.domain.com;
location / {
access_log off;
resolver 8.8.8.8;
set $backend "somebucket.s3-website-eu-west-1.amazonaws.com";
proxy_pass http://$backend;
proxy_redirect off;
proxy_set_header Host $backend;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
add_header X-Cache-Status $upstream_cache_status;
proxy_hide_header x-amz-id-2;
proxy_hide_header x-amz-request-id;
}
}
Copy link

ghost commented Nov 11, 2015

Focused dashboard,!Fine-grained permissions..?Repositoryne..!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment