Correctly rig up the Nginx part of deployment.
This commit is contained in:
parent
4d6d761915
commit
f0e6aaa32e
@ -4,6 +4,13 @@
|
|||||||
become: true
|
become: true
|
||||||
template:
|
template:
|
||||||
src: books.vvvvvvaria.org.j2
|
src: books.vvvvvvaria.org.j2
|
||||||
dest: /etc/nginx/sites-available/
|
dest: /etc/nginx/sites-available/books.vvvvvvaria.conf
|
||||||
mode: 0644
|
mode: 0644
|
||||||
notify: Reload Nginx.
|
notify: Reload Nginx.
|
||||||
|
|
||||||
|
- name: Symlink the configuration into the enabled folder.
|
||||||
|
become: true
|
||||||
|
file:
|
||||||
|
src: /etc/nginx/sites-available/books.vvvvvvaria.conf
|
||||||
|
path: /etc/nginx/sites-enabled/books.vvvvvvaria.conf
|
||||||
|
state: link
|
||||||
|
@ -18,6 +18,9 @@ server {
|
|||||||
error_log /var/log/nginx/books.vvvvvvaria.org.log;
|
error_log /var/log/nginx/books.vvvvvvaria.org.log;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
|
auth_basic "Congrats! You've reached a members only portion of the site!";
|
||||||
|
auth_basic_user_file /etc/nginx/.htpasswd;
|
||||||
|
|
||||||
proxy_bind $server_addr;
|
proxy_bind $server_addr;
|
||||||
proxy_pass http://127.0.0.1:5000;
|
proxy_pass http://127.0.0.1:5000;
|
||||||
proxy_set_header Host $http_host;
|
proxy_set_header Host $http_host;
|
||||||
|
@ -26,3 +26,9 @@
|
|||||||
name: supervisor
|
name: supervisor
|
||||||
state: started
|
state: started
|
||||||
enabled: true
|
enabled: true
|
||||||
|
|
||||||
|
- name: Ensure the XPPL group is running.
|
||||||
|
become: true
|
||||||
|
supervisorctl:
|
||||||
|
name: 'xppl:'
|
||||||
|
state: started
|
||||||
|
Loading…
Reference in New Issue
Block a user