Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: modules/discourse/files/intraforum.adblockplus.org

Issue 9422170: Run Discourse via Thin rather than FGCI (Closed)
Patch Set: Created Feb. 27, 2013, 1:34 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « modules/discourse/files/init-discourse ('k') | modules/discourse/files/sudoers » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: modules/discourse/files/intraforum.adblockplus.org
===================================================================
--- a/modules/discourse/files/intraforum.adblockplus.org
+++ b/modules/discourse/files/intraforum.adblockplus.org
@@ -1,8 +1,12 @@
+upstream discourse {
+ server unix:///tmp/discourse-thin.sock;
+}
+
server {
listen [::]:80;
server_name intraforum.adblockplus.org;
location / {
rewrite (.*) https://intraforum.adblockplus.org$1 permanent;
}
}
server {
@@ -35,15 +39,17 @@ server {
}
# If the file exists as a static file serve it directly without
# running all the other rewite tests on it
if (-f $request_filename) {
break;
}
- include /etc/nginx/fastcgi_params;
+ proxy_set_header X-Real-IP $remote_addr;
Felix Dahlke 2013/02/27 13:38:06 How about just one space between P and $?
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
+ proxy_set_header Host $http_host;
if (!-f $request_filename) {
- fastcgi_pass unix:/tmp/discourse-fastcgi.sock;
+ proxy_pass http://discourse;
break;
}
}
}
« no previous file with comments | « modules/discourse/files/init-discourse ('k') | modules/discourse/files/sudoers » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld