Created
November 6, 2013 23:02
-
-
Save schwartzie/7345786 to your computer and use it in GitHub Desktop.
Configuration to deploy ReviewBoard (http://www.reviewboard.org/) via Nginx, uWSGI, and supervisord on Debian Squeeze. Nginx with WSGI support installed using nginx-full package from Dotdeb (http://www.dotdeb.org/). uWSGI installed using pip ("pip install uwsgi") as described in http://uwsgi-docs.readthedocs.org/en/latest/Install.html#installing…
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# nginx configuration stored in /etc/nginx/sites-available/reviewboard and symlinked in /etc/nginx/sites-enabled | |
upstream reviewboard_uwsgi { | |
server localhost:12001; | |
} | |
server { | |
listen 443 ssl; | |
server_name reviewboard.example.com; | |
location / { | |
include uwsgi_params; | |
uwsgi_param X-Real-IP $remote_addr; | |
uwsgi_param Host $http_host; | |
uwsgi_pass reviewboard_uwsgi; | |
} | |
location /media { | |
alias /path/to/reviewboard/htdocs/media; | |
} | |
location /static { | |
alias /path/to/reviewboard/htdocs/static; | |
} | |
location /errordocs { | |
alias /path/to/reviewboard/htdocs/errordocs; | |
} | |
location /favicon.ico { | |
alias /path/to/reviewboard/htdocs/static/rb/images/favicon.png; | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# supervisor configuration stored in /etc/supervisor/conf.d/reviewboard.conf | |
[program:reviewboard] | |
command = /usr/local/bin/uwsgi -s 127.0.0.1:12001 --processes 2 --harakiri 60 --master --post-buffering 4096 --wsgi-file /path/to/reviewboard/htdocs/reviewboard.wsgi --disable-logging | |
user = uwsgi | |
stopsignal = INT | |
autostart = true | |
autorestart = true | |
stderr_logfile = /var/log/supervisor/reviewboard-stderr.log | |
stdout_logfile = /var/log/supervisor/reviewboard-stdout.log |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment