Adds HTTPS requests, nginx conf, and supervisor conf
This commit is contained in:
46
pocwww/poc.conf
Normal file
46
pocwww/poc.conf
Normal file
@@ -0,0 +1,46 @@
|
||||
# poc.conf
|
||||
|
||||
upstream pocwww-site {
|
||||
server 127.0.0.1:5000;
|
||||
server 127.0.0.1:5001;
|
||||
}
|
||||
|
||||
server {
|
||||
listen 80 default_server;
|
||||
listen [::]:80 default_server;
|
||||
server_name _;
|
||||
return 301 https://$host$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
# listen 80;
|
||||
|
||||
# optional ssl configuration
|
||||
|
||||
listen 443 ssl;
|
||||
ssl_certificate /root/ssl/poc.crt;
|
||||
ssl_certificate_key /root/ssl/poc.key;
|
||||
|
||||
# end of optional ssl configuration
|
||||
|
||||
server_name localhost;
|
||||
|
||||
access_log /root/poc_access.log;
|
||||
|
||||
location / {
|
||||
proxy_set_header Host $http_host;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
|
||||
client_max_body_size 10m;
|
||||
client_body_buffer_size 128k;
|
||||
proxy_connect_timeout 60s;
|
||||
proxy_send_timeout 90s;
|
||||
proxy_read_timeout 90s;
|
||||
proxy_buffering off;
|
||||
proxy_temp_file_write_size 64k;
|
||||
proxy_pass http://pocwww-site;
|
||||
proxy_redirect off;
|
||||
}
|
||||
}
|
||||
@@ -27,8 +27,8 @@
|
||||
<script src="../../assets/js/ie-emulation-modes-warning.js"></script>
|
||||
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script>
|
||||
<script src="http://code.jquery.com/ui/1.12.0/jquery-ui.min.js"></script>
|
||||
<script src="http://d3js.org/d3.v3.js"></script>
|
||||
<script src="https://code.jquery.com/ui/1.12.0/jquery-ui.min.js"></script>
|
||||
<script src="https://d3js.org/d3.v3.js"></script>
|
||||
<script src="{{request.static_url('pocwww:static/moment.min.js')}}"></script>
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.5.0/Chart.min.js"></script>
|
||||
<script type="text/javascript" src="{{request.static_url('pocwww:static/graphs.js')}}"></script>
|
||||
|
||||
27
pocwww/supervisor.conf
Normal file
27
pocwww/supervisor.conf
Normal file
@@ -0,0 +1,27 @@
|
||||
[unix_http_server]
|
||||
file=%(here)s/env/supervisor.sock
|
||||
|
||||
[supervisord]
|
||||
pidfile=%(here)s/env/supervisord.pid
|
||||
logfile=%(here)s/env/supervisord.log
|
||||
logfile_maxbytes=50MB
|
||||
logfile_backups=10
|
||||
loglevel=info
|
||||
nodaemon=false
|
||||
minfds=1024
|
||||
minprocs=200
|
||||
|
||||
[rpcinterface:supervisor]
|
||||
supervisor.rpcinterface_factory = supervisor.rpcinterface:make_main_rpcinterface
|
||||
|
||||
[supervisorctl]
|
||||
serverurl=unix://%(here)s/env/supervisor.sock
|
||||
|
||||
[program:pocwww]
|
||||
autorestart=true
|
||||
command=%(here)s/env/bin/pserve %(here)s/production.ini http_port=50%(process_num)02d
|
||||
process_name=%(program_name)s-%(process_num)01d
|
||||
numprocs=2
|
||||
numprocs_start=0
|
||||
redirect_stderr=true
|
||||
stdout_logfile=%(here)s/env/%(program_name)s-%(process_num)01d.log
|
||||
Reference in New Issue
Block a user