diff --git a/install_files/ansible-base/roles/tails-config/tasks/install_shell_extension.yml b/install_files/ansible-base/roles/tails-config/tasks/install_shell_extension.yml index f3439a2e88..aff4c5020f 100644 --- a/install_files/ansible-base/roles/tails-config/tasks/install_shell_extension.yml +++ b/install_files/ansible-base/roles/tails-config/tasks/install_shell_extension.yml @@ -1,6 +1,12 @@ --- +- name: Check for site specific file + stat: + path: group_vars/all/site-specific + register: site_specific_file + - name: Import variables include_vars: "group_vars/all/site-specific" + when: site_specific_file.stat.exists - name: Check for v3 Source Interface file stat: @@ -12,11 +18,6 @@ path: app-journalist.auth_private register: v3_journalist_file -- name: Check for site specific file - stat: - path: group_vars/all/site-specific - register: site_specific_file - - name: Look up v3 Source Interface URL. command: grep -Po '.{56}\.onion' app-sourcev3-ths changed_when: false diff --git a/install_files/ansible-base/roles/tails-config/templates/extension.js.in b/install_files/ansible-base/roles/tails-config/templates/extension.js.in index 468317c3e3..076a4349f2 100644 --- a/install_files/ansible-base/roles/tails-config/templates/extension.js.in +++ b/install_files/ansible-base/roles/tails-config/templates/extension.js.in @@ -19,8 +19,8 @@ const Domain = Gettext.domain(GETTEXT_DOMAIN) const source_interface_address = "{{ item.0.source_interface_address }}"; const journalist_interface_address = "{{ item.0.journalist_interface_address }}"; -const app_server_hostname = "{{ app_hostname }}"; -const mon_server_hostname = "{{ monitor_hostname }}"; +const app_server_hostname = "{{ app_hostname|default('app') }}"; +const mon_server_hostname = "{{ monitor_hostname|default('mon') }}"; const _ = Domain.gettext;