feat(distro): add centos-7 support
[arvados-formula.git] / test / salt / pillar / examples / nginx_workbench2_configuration.sls
1 ---
2 {%- if grains.os_family in ('RedHat',) %}
3   {%- set group = 'nginx' %}
4 {%- else %}
5   {%- set group = 'www-data' %}
6 {%- endif %}
7
8 ### ARVADOS
9 arvados:
10   config:
11     group: {{ group }}
12
13 ### NGINX
14 nginx:
15   ### SITES
16   servers:
17     managed:
18       ### DEFAULT
19       arvados_workbench2_default.conf:
20         enabled: true
21         overwrite: true
22         config:
23           - server:
24             - server_name: workbench2.fixme.example.net
25             - listen:
26               - 80
27             - location /.well-known:
28               - root: /var/www
29             - location /:
30               - return: '301 https://$host$request_uri'
31
32       arvados_workbench2_ssl.conf:
33         enabled: true
34         overwrite: true
35         config:
36           - server:
37             - server_name: workbench2.fixme.example.net
38             - listen:
39               - 443 http2 ssl
40             - index: index.html index.htm
41             - location /:
42               - root: /var/www/arvados-workbench2/workbench2
43               - try_files: '$uri $uri/ /index.html'
44               - 'if (-f $document_root/maintenance.html)':
45                 - return: 503
46             - location /config.json:
47               - return: {{ "200 '" ~ '{"API_HOST":"fixme.example.net"}' ~ "'" }}
48             - include: 'snippets/ssl_hardening_default.conf'
49             # - include: 'snippets/letsencrypt.conf'
50             - include: 'snippets/ssl_snakeoil.conf'
51             - access_log: /var/log/nginx/workbench2.fixme.example.net.access.log combined
52             - error_log: /var/log/nginx/workbench2.fixme.example.net.error.log