From 4f4850801484f7dd36700701572e95d5013b0ee6 Mon Sep 17 00:00:00 2001 From: Slavi Pantaleev Date: Mon, 17 Sep 2018 08:24:35 +0300 Subject: [PATCH] Rename variable (matrix_nginx_riot_web_data_path -> matrix_riot_web_data_path) --- CHANGELOG.md | 9 +++++++++ roles/matrix-server/defaults/main.yml | 11 +++++------ roles/matrix-server/tasks/setup_riot_web.yml | 6 +++--- .../templates/systemd/matrix-riot-web.service.j2 | 4 ++-- 4 files changed, 19 insertions(+), 11 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 222df8c4c..2681ef789 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,12 @@ +# 2018-09-17 + +## (BC Break) Renaming playbook variables + +The following playbook variables were renamed: + +- from `matrix_nginx_riot_web_data_path` to `matrix_riot_web_data_path` + + # 2018-09-07 ## Mautrix Telegram bridging support diff --git a/roles/matrix-server/defaults/main.yml b/roles/matrix-server/defaults/main.yml index f559e0a71..9268f39a4 100644 --- a/roles/matrix-server/defaults/main.yml +++ b/roles/matrix-server/defaults/main.yml @@ -111,7 +111,7 @@ matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret: "" matrix_postgres_data_path: "{{ matrix_base_data_path }}/postgres" matrix_nginx_proxy_data_path: "{{ matrix_base_data_path }}/nginx-proxy" matrix_nginx_proxy_confd_path: "{{ matrix_nginx_proxy_data_path }}/conf.d" -matrix_nginx_riot_web_data_path: "{{ matrix_base_data_path }}/riot-web" +matrix_riot_web_data_path: "{{ matrix_base_data_path }}/riot-web" matrix_coturn_base_path: "{{ matrix_base_data_path }}/coturn" matrix_coturn_config_path: "{{ matrix_coturn_base_path }}/turnserver.conf" matrix_scratchpad_dir: "{{ matrix_base_data_path }}/scratchpad" @@ -238,6 +238,10 @@ matrix_nginx_proxy_enabled: true matrix_nginx_proxy_matrix_client_api_addr_with_proxy_container: "matrix-synapse:8008" matrix_nginx_proxy_matrix_client_api_addr_sans_proxy_container: "localhost:8008" +# Specifies when to reload the matrix-nginx-proxy service so that +# a new SSL certificate could go into effect. +matrix_nginx_proxy_reload_cron_time_definition: "20 4 */5 * *" + matrix_ssl_base_path: "{{ matrix_base_data_path }}/ssl" matrix_ssl_config_dir_path: "{{ matrix_ssl_base_path }}/config" @@ -249,8 +253,3 @@ matrix_ssl_use_staging: false # Specifies when to attempt to retrieve new SSL certificates from Let's Encrypt. matrix_ssl_renew_cron_time_definition: "15 4 */5 * *" - - -# Specifies when to reload the matrix-nginx-proxy service so that -# a new SSL certificate could go into effect. -matrix_nginx_proxy_reload_cron_time_definition: "20 4 */5 * *" diff --git a/roles/matrix-server/tasks/setup_riot_web.yml b/roles/matrix-server/tasks/setup_riot_web.yml index ab67a4c00..58f864dbe 100644 --- a/roles/matrix-server/tasks/setup_riot_web.yml +++ b/roles/matrix-server/tasks/setup_riot_web.yml @@ -6,7 +6,7 @@ - name: Ensure Matrix riot-web path exists file: - path: "{{ matrix_nginx_riot_web_data_path }}" + path: "{{ matrix_riot_web_data_path }}" state: directory mode: 0750 owner: "{{ matrix_user_username }}" @@ -21,7 +21,7 @@ - name: Ensure Matrix riot-web configured template: src: "{{ role_path }}/templates/riot-web/{{ item }}.j2" - dest: "{{ matrix_nginx_riot_web_data_path }}/{{ item }}" + dest: "{{ matrix_riot_web_data_path }}/{{ item }}" mode: 0644 owner: "{{ matrix_user_username }}" group: "{{ matrix_user_username }}" @@ -58,7 +58,7 @@ - name: Ensure Matrix riot-web paths doesn't exist file: - path: "{{ matrix_nginx_riot_web_data_path }}" + path: "{{ matrix_riot_web_data_path }}" state: absent when: "not matrix_riot_web_enabled" diff --git a/roles/matrix-server/templates/systemd/matrix-riot-web.service.j2 b/roles/matrix-server/templates/systemd/matrix-riot-web.service.j2 index 07c0b7c76..d8e8d9be0 100644 --- a/roles/matrix-server/templates/systemd/matrix-riot-web.service.j2 +++ b/roles/matrix-server/templates/systemd/matrix-riot-web.service.j2 @@ -9,8 +9,8 @@ ExecStartPre=-/usr/bin/docker kill matrix-riot-web ExecStartPre=-/usr/bin/docker rm matrix-riot-web ExecStart=/usr/bin/docker run --rm --name matrix-riot-web \ --user={{ matrix_user_uid }}:{{ matrix_user_gid }} \ - -v {{ matrix_nginx_riot_web_data_path }}/config.json:/riot-web/webapp/config.json:ro \ - -v {{ matrix_nginx_riot_web_data_path }}/riot.im.conf:/data/riot.im.conf:ro \ + -v {{ matrix_riot_web_data_path }}/config.json:/riot-web/webapp/config.json:ro \ + -v {{ matrix_riot_web_data_path }}/riot.im.conf:/data/riot.im.conf:ro \ --network={{ matrix_docker_network }} \ {% if not matrix_nginx_proxy_enabled %} -p 127.0.0.1:8765:8765 \