From 388a8897f7aad9d67860a7886f91f993c3028713 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ebbe=20Ba=C3=9F?= Date: Wed, 29 Jul 2026 14:10:24 +0200 Subject: [PATCH] added tasks for server configuration --- .../setup_talk_with_hpb.yml | 31 ++++++++++++++----- 1 file changed, 23 insertions(+), 8 deletions(-) diff --git a/playbooks/linux/ubuntu-server/nextcloud_full_deployment/setup_talk_with_hpb.yml b/playbooks/linux/ubuntu-server/nextcloud_full_deployment/setup_talk_with_hpb.yml index 72311a0..65e9aca 100644 --- a/playbooks/linux/ubuntu-server/nextcloud_full_deployment/setup_talk_with_hpb.yml +++ b/playbooks/linux/ubuntu-server/nextcloud_full_deployment/setup_talk_with_hpb.yml @@ -43,12 +43,27 @@ - vars/shared_vars.yml tasks: - - name: Install Talk app - ansible.builtin.shell: | - su -s /bin/bash www-data -c \ - 'php {{ nextcloud_install_dir }}/occ app:install spreed' + - name: Install talk app + ansible.builtin.command: > + sudo -u www-data php occ app:install spreed + args: + chdir: "{{ nextcloud_install_dir }}" + register: install_result + changed_when: "'already installed' not in install_result.stdout" + failed_when: install_result.rc != 0 and 'already installed' not in install_result.stdout - - name: Enable Talk app - ansible.builtin.shell: | - su -s /bin/bash www-data -c \ - 'php {{ nextcloud_install_dir }}/occ app:enable spreed' \ No newline at end of file + - name: Configure Talk app's High Performance Backend (HPB) signaling server + ansible.builtin.command: > + sudo -u www-data php occ config:app:set spreed signaling servers + --value="{"servers":[{"server":"{{ nc_talk_hpb_domain }}","verify":true}],"secret":"{{ nc_talk_hpb_signaling_secret }}"}" + args: + chdir: "{{ nextcloud_install_dir }}" + changed_when: true + + - name: Configure Talk app's High Performance Backend (HPB) TURN server + ansible.builtin.command: > + sudo -u www-data php occ config:app:set spreed turn_servers + --value="[{"schemes":"turn","server":"{{ nc_talk_hpb_domain }}:3478","secret":"{{ nc_talk_hpb_turn_secret }}","protocols":"udp,tcp"}]" + args: + chdir: "{{ nextcloud_install_dir }}" + changed_when: true