Skip to content

Instantly share code, notes, and snippets.

@heynemann
Created August 13, 2012 14:30
Show Gist options
  • Save heynemann/3341234 to your computer and use it in GitHub Desktop.
Save heynemann/3341234 to your computer and use it in GitHub Desktop.
nginx conf for thumbor
upstream thumborbe {
server thumbor.myhost.com:8090 ;
server thumbor.myhost.com:8091 ;
server thumbor.myhost.com:8092 ;
server thumbor.myhost.com:8093 ;
server thumbor.myhost.com:8094 ;
server thumbor.myhost.com:8095 ;
}
location ~* "^/.{28}/.*(jpg|jpeg|gif|png)(#.*)?$" {
root /path/to/your/thumbor/generated/images;
expires 1M;
error_page 404 = @fetch;
}
location @fetch {
internal;
proxy_pass http://thumborbe$request_uri;
}
@eduherraiz
Copy link

I wrote another nginx config, based on this gist, that works in the case of external urls.
Take a look on this gist: https://gist.github.com/eduherraiz/9618f2dee94d7876e735

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