| @@ -20,8 +20,9 @@ matrix_client_fluffychat_docker_image_registry_prefix_upstream: "{{ matrix_clien | |||||
| matrix_client_fluffychat_docker_image_registry_prefix_upstream_default: ghcr.io/ | matrix_client_fluffychat_docker_image_registry_prefix_upstream_default: ghcr.io/ | ||||
| matrix_client_fluffychat_docker_image_force_pull: "{{ matrix_client_fluffychat_docker_image.endswith(':latest') }}" | matrix_client_fluffychat_docker_image_force_pull: "{{ matrix_client_fluffychat_docker_image.endswith(':latest') }}" | ||||
| matrix_client_fluffychat_data_path: "{{ matrix_base_data_path }}/client-fluffychat" | |||||
| matrix_client_fluffychat_container_src_files_path: "{{ matrix_client_fluffychat_data_path }}/docker-src" | |||||
| matrix_client_fluffychat_base_path: "{{ matrix_base_data_path }}/client-fluffychat" | |||||
| matrix_client_fluffychat_config_path: "{{ matrix_client_fluffychat_base_path }}/config" | |||||
| matrix_client_fluffychat_container_src_files_path: "{{ matrix_client_fluffychat_base_path }}/docker-src" | |||||
| # The base container network | # The base container network | ||||
| matrix_client_fluffychat_container_network: '' | matrix_client_fluffychat_container_network: '' | ||||
| @@ -12,7 +12,8 @@ | |||||
| owner: "{{ matrix_user_name }}" | owner: "{{ matrix_user_name }}" | ||||
| group: "{{ matrix_group_name }}" | group: "{{ matrix_group_name }}" | ||||
| with_items: | with_items: | ||||
| - {path: "{{ matrix_client_fluffychat_data_path }}", when: true} | |||||
| - {path: "{{ matrix_client_fluffychat_base_path }}", when: true} | |||||
| - {path: "{{ matrix_client_fluffychat_config_path }}", when: true} | |||||
| - {path: "{{ matrix_client_fluffychat_container_src_files_path }}", when: "{{ matrix_client_fluffychat_container_image_self_build }}"} | - {path: "{{ matrix_client_fluffychat_container_src_files_path }}", when: "{{ matrix_client_fluffychat_container_image_self_build }}"} | ||||
| when: "item.when | bool" | when: "item.when | bool" | ||||
| @@ -52,13 +53,13 @@ | |||||
| - name: Ensure FluffyChat Web config files installed | - name: Ensure FluffyChat Web config files installed | ||||
| ansible.builtin.template: | ansible.builtin.template: | ||||
| src: "{{ item.src }}" | src: "{{ item.src }}" | ||||
| dest: "{{ matrix_client_fluffychat_data_path }}/{{ item.name }}" | |||||
| dest: "{{ item.dest }}" | |||||
| mode: 0644 | mode: 0644 | ||||
| owner: "{{ matrix_user_name }}" | owner: "{{ matrix_user_name }}" | ||||
| group: "{{ matrix_group_name }}" | group: "{{ matrix_group_name }}" | ||||
| with_items: | with_items: | ||||
| - {src: "{{ role_path }}/templates/labels.j2", name: "labels"} | |||||
| - {src: "{{ role_path }}/templates/config.json.j2", name: "config.json"} | |||||
| - {src: "{{ role_path }}/templates/labels.j2", dest: "{{ matrix_client_fluffychat_base_path }}/labels"} | |||||
| - {src: "{{ role_path }}/templates/config.json.j2", dest: "{{ matrix_client_fluffychat_config_path }}/config.json"} | |||||
| when: "item.src is not none" | when: "item.src is not none" | ||||
| - name: Ensure FluffyChat Web container network is created | - name: Ensure FluffyChat Web container network is created | ||||
| @@ -25,5 +25,5 @@ | |||||
| - name: Ensure FluffyChat Web path doesn't exist | - name: Ensure FluffyChat Web path doesn't exist | ||||
| ansible.builtin.file: | ansible.builtin.file: | ||||
| path: "{{ matrix_client_fluffychat_data_path }}" | |||||
| path: "{{ matrix_client_fluffychat_base_path }}" | |||||
| state: absent | state: absent | ||||
| @@ -24,8 +24,8 @@ ExecStartPre={{ devture_systemd_docker_base_host_command_docker }} create \ | |||||
| {% if matrix_client_fluffychat_container_http_host_bind_port %} | {% if matrix_client_fluffychat_container_http_host_bind_port %} | ||||
| -p {{ matrix_client_fluffychat_container_http_host_bind_port }}:{{ matrix_client_fluffychat_container_http_port }} \ | -p {{ matrix_client_fluffychat_container_http_host_bind_port }}:{{ matrix_client_fluffychat_container_http_port }} \ | ||||
| {% endif %} | {% endif %} | ||||
| --label-file={{ matrix_client_fluffychat_data_path }}/labels \ | |||||
| --mount type=bind,src={{ matrix_client_fluffychat_data_path }}/config.json,dst=/var/public/config.json,ro \ | |||||
| --label-file={{ matrix_client_fluffychat_base_path }}/labels \ | |||||
| --mount type=bind,src={{ matrix_client_fluffychat_config_path }}/config.json,dst=/var/public/config.json,ro \ | |||||
| --tmpfs=/tmp:rw,noexec,nosuid,size=10m \ | --tmpfs=/tmp:rw,noexec,nosuid,size=10m \ | ||||
| {% for arg in matrix_client_fluffychat_container_extra_arguments %} | {% for arg in matrix_client_fluffychat_container_extra_arguments %} | ||||
| {{ arg }} \ | {{ arg }} \ | ||||