0.1.0-DEV-20191030-122725

-------------------------
    * INITIAL:
      - initial commit
This commit is contained in:
2019-10-30 00:27:10 -04:00
commit c7ad8909d8
13 changed files with 519 additions and 0 deletions

39
templates/proxy_site.j2 Normal file
View File

@ -0,0 +1,39 @@
#####################################################
# The Zen Garden Network #
# #
# Configuration : {{ proxy_site_conf_dir }}/{{ item.key }}.conf #
# Version : {{ proxy_site_version }}-{{ proxy_site_revision }} #
# #
# Chris H. <chris@thezengarden.net> #
#####################################################
### Configuration for: {{ item.key }}
################################################
server {
listen 443 ssl;
server_name {{ item.key }} {% if proxy_sites[item.key]['aliases'] is defined %}{{ proxy_sites[item.key]['aliases'] }}{% endif %};
ssl_certificate {{ proxy_sites[item.key]['ssl_cert'] | default(proxy_site_ssl_certificate) }};
ssl_certificate_key {{ proxy_sites[item.key]['ssl_key'] | default(proxy_site_ssl_certificate_key) }};
ssl_session_cache shared:SSL:10m;
ssl_protocols {{ proxy_site_ssl_protocols }};
ssl_ciphers {{ proxy_site_ssl_ciphers }};
ssl_prefer_server_ciphers on;
access_log {{ proxy_site_log_path }}/{{ item.key }}.log;
location / {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header Host $host;
proxy_pass {{ proxy_sites[item.key]['proto'] }}://{{ proxy_sites[item.key]['dest'] }}:{{ proxy_sites[item.key]['port'] }};
# re-write redirects to http as to https
proxy_redirect http:// https://;
}
}

View File

@ -0,0 +1,37 @@
#####################################################
# The Zen Garden Network #
# #
# Configuration : {{ proxy_site_file }} #
# Version : {{ proxy_site_version }}-{{ proxy_site_revision }} #
# #
# Chris H. <chris@thezengarden.net> #
#####################################################
{% for site in proxy_sites %}
### Configuration for: {{ site }}
################################################
server {
listen 443 ssl;
server_name {{ site }};
ssl_certificate {{ proxy_site_ssl_certificate }};
ssl_certificate_key {{ proxy_site_ssl_certificate_key }};
ssl_session_cache shared:SSL:10m;
ssl_protocols {{ proxy_site_ssl_protocols }};
ssl_ciphers {{ proxy_site_ssl_ciphers }};
ssl_prefer_server_ciphers on;
access_log {{ proxy_site_log_path }}/{{ site }}.log;
location / {
proxy_pass {{ proxy_sites[site]['proto'] }}://{{ proxy_sites[site]['dest'] }}:{{ proxy_sites[site]['port'] }};
proxy_set_header Host $host;
# re-write redirects to http as to https
proxy_redirect http:// https://;
}
}
{% endfor %}