roles/nginx/static added

wip
Felix Stupp 5 years ago
parent 309d23ba8a
commit bdf96b6eeb
Signed by: zocker
GPG Key ID: 93E1BD26F6B02FB7

@ -0,0 +1,4 @@
---
# domain: example.com
root_directory: "{{ global_webservers_directory }}/{{ domain }}"

@ -0,0 +1,7 @@
---
allow_duplicates: yes
dependencies:
- role: acme/certificate
- role: nginx/application

@ -0,0 +1,10 @@
---
- name: Configure static for {{ domain }}
template:
src: static.conf
dest: "{{ nginx_sites_directory }}/{{ domain }}"
owner: root
group: root
mode: "u=rw,g=r,o=r"
notify: reload nginx

@ -0,0 +1,18 @@
server {
listen 443 ssl http2;
listen [::]:443 ssl http2;
server_name {{ domain }};
ssl on;
ssl_certificate {{ acme_certificate_location }};
ssl_certificate_key {{ acme_key_location }};
root {{ root_directory }};
include {{ nginx_snippets_directory }}/https;
include {{ nginx_snippets_directory }}/root;
location / {
try_files $uri $uri/ =404;
}
}
Loading…
Cancel
Save