blob: ce920ebbd7e6d5093e0c8fc91d5ae02e5802d523 [file] [log] [blame]
Zack Williams70996442020-10-01 22:09:49 -07001---
2# timeesheets molecule/default/prepare.yml
3#
4# SPDX-FileCopyrightText: © 2020 Open Networking Foundation <support@opennetworking.org>
5# SPDX-License-Identifier: Apache-2.0
6
7- name: Prepare for Timesheets by installing dependency roles
8 hosts: all
9
10 vars:
11 pgsql_users:
12 - name: "timesheets_db_user"
13 password: "timesheets_db_pass"
14 pgsql_databases:
15 - name: "timesheets"
16 owner: "timesheets_db_user"
17
18 acme_username: "www-data" # make independent of the acme role
19 vhosts:
20 - name: "timesheets.example.com"
21 default_server: true
22 custom_root: "/opt/timesheets/ui/dist/timesheetsui"
23 extra_config: |
24 location /rest {
25 proxy_pass http://localhost:3000;
26 proxy_buffering off;
27 proxy_http_version 1.1;
28 proxy_read_timeout 60;
29 proxy_connect_timeout 90;
30
31 proxy_set_header Host $host;
32 proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
33 proxy_set_header X-Forwarded-Proto $scheme;
34 proxy_set_header X-Real-IP $remote_addr;
35 proxy_set_header Accept-Encoding "";
36 }
37
38
39 pre_tasks:
40 - name: Install GPG to support adding apt repo keys
41 apt:
42 name: "gpg"
43 state: "present"
44 update_cache: true
45
46 roles:
47 - nodejs
48 - nginx
49 - postgresql