Skip to content

Commit

Permalink
Fixed this mofo thing!
Browse files Browse the repository at this point in the history
  • Loading branch information
pgib committed Jan 9, 2012
1 parent 75c92dd commit 51112be
Showing 1 changed file with 12 additions and 3 deletions.
15 changes: 12 additions & 3 deletions virtualhosts/adam.localhost.coverallcrew.com.conf
Expand Up @@ -5,9 +5,17 @@ server

root /usr/local/sites/ayv/adam/public;
index index.html;

log_subrequest on;
log_not_found on;

#location ^~ /upload/medias/
location ~* /medias/.*?/upload
#location ~ upload$
{
log_subrequest on;
log_not_found on;

# pass request body to here
upload_pass @fast_upload_endpoint;

Expand All @@ -22,8 +30,8 @@ server
# Set specified fields in request body
# this puts the original filename, new path+filename and content type in the requests params
upload_set_form_field upload[fast_asset][original_name] "$upload_file_name";
upload_set_form_field upload[fast_asset][content_type] "$upload_content_type";
upload_set_form_field upload[fast_asset][filepath] "$upload_tmp_path";
upload_set_form_field upload[fast_asset][content_type] "$upload_content_type";
upload_set_form_field upload[fast_asset][filepath] "$upload_tmp_path";

upload_pass_form_field "^theme_id$|^blog_id$|^authenticity_token$|^format$";
upload_cleanup 400 404 499 500-505;
Expand All @@ -36,7 +44,7 @@ server
proxy_pass http://adam;
}

location ^~ /
location ~* /.+
{
proxy_pass_request_headers on;
proxy_ignore_headers Expires Cache-Control;
Expand All @@ -57,6 +65,7 @@ server
}
}


gzip on;
gzip_min_length 1000;
gzip_proxied expired no-cache no-store private auth;
Expand Down

0 comments on commit 51112be

Please sign in to comment.