mirror of
https://github.com/spantaleev/matrix-docker-ansible-deploy.git
synced 2025-01-30 20:05:01 +01:00
Variables rename (matrix_livekit_server_ -> livekit_server_) to prepare for role extraction
This commit is contained in:
parent
1e82530080
commit
1838a541ae
@ -34,10 +34,10 @@ Add the following configuration to your `inventory/host_vars/matrix.DOMAIN/vars.
|
|||||||
# Enable dependent services
|
# Enable dependent services
|
||||||
keydb_enabled: true
|
keydb_enabled: true
|
||||||
matrix_element_call_enabled: true
|
matrix_element_call_enabled: true
|
||||||
matrix_livekit_server_enabled: true
|
livekit_server_enabled: true
|
||||||
matrix_jwt_service_enabled: true
|
matrix_jwt_service_enabled: true
|
||||||
# Set a secure key for LiveKit authentication
|
# Set a secure key for LiveKit authentication
|
||||||
matrix_livekit_server_dev_key: 'your-secure-livekit-key'
|
livekit_server_dev_key: 'your-secure-livekit-key'
|
||||||
```
|
```
|
||||||
|
|
||||||
## Installing
|
## Installing
|
||||||
@ -68,4 +68,4 @@ Ensure these ports are open and forwarded appropriately to allow traffic to flow
|
|||||||
|
|
||||||
## Additional Information
|
## Additional Information
|
||||||
|
|
||||||
Refer to the Element Call documentation for more details on configuring and using Element Call.
|
Refer to the Element Call documentation for more details on configuring and using Element Call.
|
||||||
|
@ -8,11 +8,11 @@ See the project's [documentation](https://github.com/livekit/livekit) to learn m
|
|||||||
|
|
||||||
## Decide on a domain and path
|
## Decide on a domain and path
|
||||||
|
|
||||||
By default, Livekit is configured to be served on the Matrix domain (`sfu.DOMAIN`, controlled by the `matrix_livekit_server_hostname` variable).
|
By default, Livekit is configured to be served on the Matrix domain (`sfu.DOMAIN`, controlled by the `livekit_server_hostname` variable).
|
||||||
|
|
||||||
This makes it easy to set it up, **without** having to adjust your DNS records manually.
|
This makes it easy to set it up, **without** having to adjust your DNS records manually.
|
||||||
|
|
||||||
If you'd like to run Livekit on another hostname or path, use the `matrix_livekit_server_hostname` variable.
|
If you'd like to run Livekit on another hostname or path, use the `livekit_server_hostname` variable.
|
||||||
|
|
||||||
## Adjusting DNS records
|
## Adjusting DNS records
|
||||||
|
|
||||||
@ -26,7 +26,7 @@ Ensure that the following DNS names have a public IP/FQDN:
|
|||||||
Add the following configuration to your `inventory/host_vars/matrix.DOMAIN/vars.yml` file:
|
Add the following configuration to your `inventory/host_vars/matrix.DOMAIN/vars.yml` file:
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
matrix_livekit_server_enabled: true
|
livekit_server_enabled: true
|
||||||
# Set a secure key for LiveKit authentication
|
# Set a secure key for LiveKit authentication
|
||||||
matrix_element_call_livekit_dev_key: 'your-secure-livekit-key'
|
matrix_element_call_livekit_dev_key: 'your-secure-livekit-key'
|
||||||
```
|
```
|
||||||
@ -53,4 +53,4 @@ Ensure these ports are open and forwarded appropriately to allow traffic to flow
|
|||||||
|
|
||||||
## Additional Information
|
## Additional Information
|
||||||
|
|
||||||
Refer to the Livekit documentation for more details on configuring and using Livekit.
|
Refer to the Livekit documentation for more details on configuring and using Livekit.
|
||||||
|
@ -442,7 +442,7 @@ devture_systemd_service_manager_services_list_auto: |
|
|||||||
+
|
+
|
||||||
([{'name': 'matrix-jwt-service.service', 'priority': 3000, 'groups': ['matrix', 'jwt-service']}] if matrix_jwt_service_enabled else [])
|
([{'name': 'matrix-jwt-service.service', 'priority': 3000, 'groups': ['matrix', 'jwt-service']}] if matrix_jwt_service_enabled else [])
|
||||||
+
|
+
|
||||||
([{'name': 'matrix-livekit-server.service', 'priority': 3000, 'groups': ['matrix', 'livekit-server']}] if matrix_livekit_server_enabled else [])
|
([{'name': 'matrix-livekit-server.service', 'priority': 3000, 'groups': ['matrix', 'livekit-server']}] if livekit_server_enabled else [])
|
||||||
+
|
+
|
||||||
([{'name': 'matrix-registration.service', 'priority': 4000, 'groups': ['matrix', 'registration', 'matrix-registration']}] if matrix_registration_enabled else [])
|
([{'name': 'matrix-registration.service', 'priority': 4000, 'groups': ['matrix', 'registration', 'matrix-registration']}] if matrix_registration_enabled else [])
|
||||||
+
|
+
|
||||||
@ -6063,27 +6063,27 @@ matrix_element_call_container_labels_traefik_tls_certResolver: "{{ traefik_certR
|
|||||||
########################################################################
|
########################################################################
|
||||||
|
|
||||||
# Matrix Livekit Server Configuration
|
# Matrix Livekit Server Configuration
|
||||||
matrix_livekit_server_enabled: false # Default is false; should be enabled in host_vars as needed
|
livekit_server_enabled: false # Default is false; should be enabled in host_vars as needed
|
||||||
matrix_livekit_server_version: "latest" # Default version; can be overridden in host_vars
|
livekit_server_version: "latest" # Default version; can be overridden in host_vars
|
||||||
matrix_livekit_server_scheme: "https"
|
livekit_server_scheme: "https"
|
||||||
matrix_livekit_server_hostname: "sfu.{{ matrix_domain }}" # Default hostname; should be overridden in host_vars if different
|
livekit_server_hostname: "sfu.{{ matrix_domain }}" # Default hostname; should be overridden in host_vars if different
|
||||||
matrix_livekit_server_path_prefix: "/"
|
livekit_server_path_prefix: "/"
|
||||||
matrix_livekit_server_base_path: "{{ matrix_base_data_path }}/livekit-server"
|
livekit_server_base_path: "{{ matrix_base_data_path }}/livekit-server"
|
||||||
matrix_livekit_server_container_image: "livekit/livekit-server:{{ matrix_livekit_server_version }}"
|
livekit_server_container_image: "livekit/livekit-server:{{ livekit_server_version }}"
|
||||||
matrix_livekit_server_container_image_force_pull: true
|
livekit_server_container_image_force_pull: true
|
||||||
|
|
||||||
# Docker network configuration for Livekit
|
# Docker network configuration for Livekit
|
||||||
matrix_livekit_server_container_network: "{{ matrix_addons_container_network }}"
|
livekit_server_container_network: "{{ matrix_addons_container_network }}"
|
||||||
matrix_livekit_server_container_additional_networks: "{{ [matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_livekit_server_container_labels_traefik_enabled and matrix_playbook_reverse_proxyable_services_additional_network) else [] }}"
|
livekit_server_container_additional_networks: "{{ [matrix_playbook_reverse_proxyable_services_additional_network] if (livekit_server_container_labels_traefik_enabled and matrix_playbook_reverse_proxyable_services_additional_network) else [] }}"
|
||||||
|
|
||||||
# Traefik Configuration for Livekit
|
# Traefik Configuration for Livekit
|
||||||
matrix_livekit_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
|
matrix_livekit_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
|
||||||
matrix_livekit_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
|
matrix_livekit_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
|
||||||
matrix_livekit_server_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
|
livekit_server_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
|
||||||
matrix_livekit_server_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
|
livekit_server_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
|
||||||
|
|
||||||
# LiveKit Service Configuration
|
# LiveKit Service Configuration
|
||||||
matrix_livekit_server_livekit_dev_key: "{{ matrix_livekit_server_dev_key }}" # LiveKit dev key
|
livekit_server_livekit_dev_key: "{{ livekit_server_dev_key }}" # LiveKit dev key
|
||||||
|
|
||||||
########################################################################
|
########################################################################
|
||||||
# #
|
# #
|
||||||
@ -6126,4 +6126,4 @@ matrix_jwt_service_url: "https://sfu-jwt.{{ matrix_domain }}" # Default JWT ser
|
|||||||
# #
|
# #
|
||||||
# /matrix-jwt-service #
|
# /matrix-jwt-service #
|
||||||
# #
|
# #
|
||||||
########################################################################
|
########################################################################
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Environment variables for JWT Service
|
# Environment variables for JWT Service
|
||||||
LIVEKIT_KEY=devkey
|
LIVEKIT_KEY=devkey
|
||||||
LIVEKIT_URL=wss://{{ matrix_livekit_server_hostname }}:443
|
LIVEKIT_URL=wss://{{ livekit_server_hostname }}:443
|
||||||
LIVEKIT_SECRET={{ matrix_livekit_server_dev_key }}
|
LIVEKIT_SECRET={{ livekit_server_dev_key }}
|
||||||
|
@ -1,49 +1,49 @@
|
|||||||
---
|
---
|
||||||
# Enable or disable matrix-livekit-server deployment
|
# Enable or disable matrix-livekit-server deployment
|
||||||
matrix_livekit_server_enabled: false
|
livekit_server_enabled: false
|
||||||
|
|
||||||
# Base path configuration
|
# Base path configuration
|
||||||
matrix_livekit_server_base_path: "{{ matrix_base_data_path }}/livekit-server"
|
livekit_server_base_path: "{{ matrix_base_data_path }}/livekit-server"
|
||||||
|
|
||||||
# Docker network configuration
|
# Docker network configuration
|
||||||
matrix_livekit_server_container_network: ''
|
livekit_server_container_network: ''
|
||||||
matrix_livekit_server_container_http_host_bind_port: ''
|
livekit_server_container_http_host_bind_port: ''
|
||||||
matrix_livekit_server_container_additional_networks: [] # No additional networks by default
|
livekit_server_container_additional_networks: [] # No additional networks by default
|
||||||
|
|
||||||
# Docker images
|
# Docker images
|
||||||
matrix_livekit_server_image: "livekit/livekit-server:latest"
|
livekit_server_image: "livekit/livekit-server:latest"
|
||||||
|
|
||||||
# LiveKit configuration
|
# LiveKit configuration
|
||||||
matrix_livekit_server_livekit_server_dev_key: "{{ matrix_livekit_server_dev_key }}" # Must be defined in host_vars
|
livekit_server_livekit_server_dev_key: "{{ livekit_server_dev_key }}" # Must be defined in host_vars
|
||||||
matrix_livekit_server_jwt_secret: "{{ matrix_element_call_jwt_secret }}" # Must be defined in host_vars
|
livekit_server_jwt_secret: "{{ matrix_element_call_jwt_secret }}" # Must be defined in host_vars
|
||||||
matrix_livekit_server_hostname: "sfu.{{ matrix_domain }}"
|
livekit_server_hostname: "sfu.{{ matrix_domain }}"
|
||||||
|
|
||||||
# Traefik Configuration for Element Call
|
# Traefik Configuration for Element Call
|
||||||
matrix_livekit_server_container_labels_traefik_enabled: true
|
livekit_server_container_labels_traefik_enabled: true
|
||||||
matrix_livekit_server_container_labels_traefik_docker_network: "{{ matrix_livekit_server_container_network }}"
|
livekit_server_container_labels_traefik_docker_network: "{{ livekit_server_container_network }}"
|
||||||
matrix_livekit_server_container_labels_traefik_hostname: "{{ matrix_livekit_server_hostname }}"
|
livekit_server_container_labels_traefik_hostname: "{{ livekit_server_hostname }}"
|
||||||
# The path prefix must either be `/` or not end with a slash (e.g. `/element`).
|
# The path prefix must either be `/` or not end with a slash (e.g. `/element`).
|
||||||
matrix_livekit_server_container_labels_traefik_path_prefix: "{{ matrix_livekit_server_path_prefix }}"
|
livekit_server_container_labels_traefik_path_prefix: "{{ livekit_server_path_prefix }}"
|
||||||
matrix_livekit_server_container_labels_traefik_rule: "Host(`{{ matrix_livekit_server_container_labels_traefik_hostname }}`){% if matrix_livekit_server_container_labels_traefik_path_prefix != '/' %} && PathPrefix(`{{ matrix_livekit_server_container_labels_traefik_path_prefix }}`){% endif %}"
|
livekit_server_container_labels_traefik_rule: "Host(`{{ livekit_server_container_labels_traefik_hostname }}`){% if livekit_server_container_labels_traefik_path_prefix != '/' %} && PathPrefix(`{{ livekit_server_container_labels_traefik_path_prefix }}`){% endif %}"
|
||||||
matrix_livekit_server_container_labels_traefik_priority: 0
|
livekit_server_container_labels_traefik_priority: 0
|
||||||
matrix_livekit_server_container_labels_traefik_entrypoints: web-secure
|
livekit_server_container_labels_traefik_entrypoints: web-secure
|
||||||
matrix_livekit_server_container_labels_traefik_tls: "{{ matrix_livekit_server_container_labels_traefik_entrypoints != 'web' }}"
|
livekit_server_container_labels_traefik_tls: "{{ livekit_server_container_labels_traefik_entrypoints != 'web' }}"
|
||||||
matrix_livekit_server_container_labels_traefik_tls_certResolver: default # noqa var-naming
|
livekit_server_container_labels_traefik_tls_certResolver: default # noqa var-naming
|
||||||
|
|
||||||
# Controls which additional headers to attach to all HTTP responses.
|
# Controls which additional headers to attach to all HTTP responses.
|
||||||
# To add your own headers, use `matrix_livekit_server_container_labels_traefik_additional_response_headers_custom`
|
# To add your own headers, use `livekit_server_container_labels_traefik_additional_response_headers_custom`
|
||||||
matrix_livekit_server_container_labels_traefik_additional_response_headers: "{{ matrix_livekit_server_container_labels_traefik_additional_response_headers_auto | combine(matrix_livekit_server_container_labels_traefik_additional_response_headers_custom) }}"
|
livekit_server_container_labels_traefik_additional_response_headers: "{{ livekit_server_container_labels_traefik_additional_response_headers_auto | combine(livekit_server_container_labels_traefik_additional_response_headers_custom) }}"
|
||||||
matrix_livekit_server_container_labels_traefik_additional_response_headers_auto: |
|
livekit_server_container_labels_traefik_additional_response_headers_auto: |
|
||||||
{{
|
{{
|
||||||
{}
|
{}
|
||||||
| combine ({'X-XSS-Protection': matrix_livekit_server_http_header_xss_protection} if matrix_livekit_server_http_header_xss_protection else {})
|
| combine ({'X-XSS-Protection': livekit_server_http_header_xss_protection} if livekit_server_http_header_xss_protection else {})
|
||||||
| combine ({'X-Frame-Options': matrix_livekit_server_http_header_frame_options} if matrix_livekit_server_http_header_frame_options else {})
|
| combine ({'X-Frame-Options': livekit_server_http_header_frame_options} if livekit_server_http_header_frame_options else {})
|
||||||
| combine ({'X-Content-Type-Options': matrix_livekit_server_http_header_content_type_options} if matrix_livekit_server_http_header_content_type_options else {})
|
| combine ({'X-Content-Type-Options': livekit_server_http_header_content_type_options} if livekit_server_http_header_content_type_options else {})
|
||||||
| combine ({'Content-Security-Policy': matrix_livekit_server_http_header_content_security_policy} if matrix_livekit_server_http_header_content_security_policy else {})
|
| combine ({'Content-Security-Policy': livekit_server_http_header_content_security_policy} if livekit_server_http_header_content_security_policy else {})
|
||||||
| combine ({'Permission-Policy': matrix_livekit_server_http_header_content_permission_policy} if matrix_livekit_server_http_header_content_permission_policy else {})
|
| combine ({'Permission-Policy': livekit_server_http_header_content_permission_policy} if livekit_server_http_header_content_permission_policy else {})
|
||||||
| combine ({'Strict-Transport-Security': matrix_livekit_server_http_header_strict_transport_security} if matrix_livekit_server_http_header_strict_transport_security and matrix_livekit_server_container_labels_traefik_tls else {})
|
| combine ({'Strict-Transport-Security': livekit_server_http_header_strict_transport_security} if livekit_server_http_header_strict_transport_security and livekit_server_container_labels_traefik_tls else {})
|
||||||
}}
|
}}
|
||||||
matrix_livekit_server_container_labels_traefik_additional_response_headers_custom: {}
|
livekit_server_container_labels_traefik_additional_response_headers_custom: {}
|
||||||
|
|
||||||
# matrix_client_element_container_labels_additional_labels contains a multiline string with additional labels to add to the container label file.
|
# matrix_client_element_container_labels_additional_labels contains a multiline string with additional labels to add to the container label file.
|
||||||
# See `../templates/labels.j2` for details.
|
# See `../templates/labels.j2` for details.
|
||||||
@ -52,16 +52,16 @@ matrix_livekit_server_container_labels_traefik_additional_response_headers_custo
|
|||||||
# matrix_client_element_container_labels_additional_labels: |
|
# matrix_client_element_container_labels_additional_labels: |
|
||||||
# my.label=1
|
# my.label=1
|
||||||
# another.label="here"
|
# another.label="here"
|
||||||
matrix_livekit_server_container_labels_additional_labels: ''
|
livekit_server_container_labels_additional_labels: ''
|
||||||
|
|
||||||
# A list of extra arguments to pass to the container
|
# A list of extra arguments to pass to the container
|
||||||
matrix_livekit_server_container_extra_arguments: []
|
livekit_server_container_extra_arguments: []
|
||||||
|
|
||||||
# Additional environment variables for the container
|
# Additional environment variables for the container
|
||||||
matrix_livekit_server_environment_variables_additional: {}
|
livekit_server_environment_variables_additional: {}
|
||||||
|
|
||||||
# List of systemd services that matrix-element-call.service depends on
|
# List of systemd services that matrix-element-call.service depends on
|
||||||
matrix_livekit_server_systemd_required_services_list: "{{ [devture_systemd_docker_base_docker_service_name] if devture_systemd_docker_base_docker_service_name else [] }}"
|
livekit_server_systemd_required_services_list: "{{ [devture_systemd_docker_base_docker_service_name] if devture_systemd_docker_base_docker_service_name else [] }}"
|
||||||
|
|
||||||
# Specifies the value of the `X-XSS-Protection` header
|
# Specifies the value of the `X-XSS-Protection` header
|
||||||
# Stops pages from loading when they detect reflected cross-site scripting (XSS) attacks.
|
# Stops pages from loading when they detect reflected cross-site scripting (XSS) attacks.
|
||||||
@ -69,27 +69,27 @@ matrix_livekit_server_systemd_required_services_list: "{{ [devture_systemd_docke
|
|||||||
# Learn more about it is here:
|
# Learn more about it is here:
|
||||||
# - https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-XSS-Protection
|
# - https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-XSS-Protection
|
||||||
# - https://portswigger.net/web-security/cross-site-scripting/reflected
|
# - https://portswigger.net/web-security/cross-site-scripting/reflected
|
||||||
matrix_livekit_server_http_header_xss_protection: ''
|
livekit_server_http_header_xss_protection: ''
|
||||||
|
|
||||||
# Specifies the value of the `X-Frame-Options` header which controls whether framing can happen.
|
# Specifies the value of the `X-Frame-Options` header which controls whether framing can happen.
|
||||||
# See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Frame-Options
|
# See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Frame-Options
|
||||||
matrix_livekit_server_http_header_frame_options: ''
|
livekit_server_http_header_frame_options: ''
|
||||||
|
|
||||||
# Specifies the value of the `X-Content-Type-Options` header.
|
# Specifies the value of the `X-Content-Type-Options` header.
|
||||||
# See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Content-Type-Options
|
# See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Content-Type-Options
|
||||||
matrix_livekit_server_http_header_content_type_options: ''
|
livekit_server_http_header_content_type_options: ''
|
||||||
|
|
||||||
# Specifies the value of the `Content-Security-Policy` header.
|
# Specifies the value of the `Content-Security-Policy` header.
|
||||||
# See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy
|
# See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy
|
||||||
matrix_livekit_server_http_header_content_security_policy: ''
|
livekit_server_http_header_content_security_policy: ''
|
||||||
|
|
||||||
# Specifies the value of the `Permission-Policy` header.
|
# Specifies the value of the `Permission-Policy` header.
|
||||||
# See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Permission-Policy
|
# See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Permission-Policy
|
||||||
matrix_livekit_server_http_header_content_permission_policy: ''
|
livekit_server_http_header_content_permission_policy: ''
|
||||||
|
|
||||||
# Specifies the value of the `Strict-Transport-Security` header.
|
# Specifies the value of the `Strict-Transport-Security` header.
|
||||||
# See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Strict-Transport-Security
|
# See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Strict-Transport-Security
|
||||||
matrix_livekit_server_http_header_strict_transport_security: ''
|
livekit_server_http_header_strict_transport_security: ''
|
||||||
|
|
||||||
# Controls whether to send a "Permissions-Policy interest-cohort=();" header along with all responses
|
# Controls whether to send a "Permissions-Policy interest-cohort=();" header along with all responses
|
||||||
#
|
#
|
||||||
@ -99,8 +99,8 @@ matrix_livekit_server_http_header_strict_transport_security: ''
|
|||||||
# - https://amifloced.org/
|
# - https://amifloced.org/
|
||||||
#
|
#
|
||||||
# Of course, a better solution is to just stop using browsers (like Chrome), which participate in such tracking practices.
|
# Of course, a better solution is to just stop using browsers (like Chrome), which participate in such tracking practices.
|
||||||
# See: `matrix_livekit_server_content_permission_policy`
|
# See: `livekit_server_content_permission_policy`
|
||||||
matrix_livekit_server_floc_optout_enabled: false
|
livekit_server_floc_optout_enabled: false
|
||||||
|
|
||||||
# Controls if HSTS preloading is enabled
|
# Controls if HSTS preloading is enabled
|
||||||
#
|
#
|
||||||
@ -111,5 +111,5 @@ matrix_livekit_server_floc_optout_enabled: false
|
|||||||
# - https://en.wikipedia.org/wiki/HTTP_Strict_Transport_Security
|
# - https://en.wikipedia.org/wiki/HTTP_Strict_Transport_Security
|
||||||
# - https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Strict-Transport-Security
|
# - https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Strict-Transport-Security
|
||||||
# - https://hstspreload.org/#opt-in
|
# - https://hstspreload.org/#opt-in
|
||||||
# See: `matrix_livekit_server_http_header_strict_transport_security`
|
# See: `livekit_server_http_header_strict_transport_security`
|
||||||
matrix_livekit_server_hsts_preload_enabled: true
|
livekit_server_hsts_preload_enabled: true
|
||||||
|
@ -10,13 +10,13 @@
|
|||||||
owner: "{{ matrix_user_username }}"
|
owner: "{{ matrix_user_username }}"
|
||||||
group: "{{ matrix_user_groupname }}"
|
group: "{{ matrix_user_groupname }}"
|
||||||
with_items:
|
with_items:
|
||||||
- path: "{{ matrix_livekit_server_base_path }}"
|
- path: "{{ livekit_server_base_path }}"
|
||||||
|
|
||||||
# Ensure Configuration Files are in Place
|
# Ensure Configuration Files are in Place
|
||||||
- name: Ensure LiveKit livekit.yaml is in place
|
- name: Ensure LiveKit livekit.yaml is in place
|
||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
src: "{{ role_path }}/templates/livekit.yaml.j2"
|
src: "{{ role_path }}/templates/livekit.yaml.j2"
|
||||||
dest: "{{ matrix_livekit_server_base_path }}/livekit.yaml"
|
dest: "{{ livekit_server_base_path }}/livekit.yaml"
|
||||||
mode: 0640
|
mode: 0640
|
||||||
owner: "{{ matrix_user_username }}"
|
owner: "{{ matrix_user_username }}"
|
||||||
group: "{{ matrix_user_groupname }}"
|
group: "{{ matrix_user_groupname }}"
|
||||||
@ -24,7 +24,7 @@
|
|||||||
- name: Ensure LiveKit labels file is in place
|
- name: Ensure LiveKit labels file is in place
|
||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
src: "{{ role_path }}/templates/labels.j2"
|
src: "{{ role_path }}/templates/labels.j2"
|
||||||
dest: "{{ matrix_livekit_server_base_path }}/labels"
|
dest: "{{ livekit_server_base_path }}/labels"
|
||||||
mode: 0640
|
mode: 0640
|
||||||
owner: "{{ matrix_user_username }}"
|
owner: "{{ matrix_user_username }}"
|
||||||
group: "{{ matrix_user_groupname }}"
|
group: "{{ matrix_user_groupname }}"
|
||||||
@ -32,7 +32,7 @@
|
|||||||
# Ensure Docker Images are Pulled
|
# Ensure Docker Images are Pulled
|
||||||
- name: Ensure LiveKit Docker image is pulled
|
- name: Ensure LiveKit Docker image is pulled
|
||||||
community.docker.docker_image:
|
community.docker.docker_image:
|
||||||
name: "{{ matrix_livekit_server_image }}"
|
name: "{{ livekit_server_image }}"
|
||||||
source: pull
|
source: pull
|
||||||
register: livekit_image_result
|
register: livekit_image_result
|
||||||
retries: 3
|
retries: 3
|
||||||
@ -44,4 +44,4 @@
|
|||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
src: "{{ role_path }}/templates/systemd/matrix-livekit-server.service.j2"
|
src: "{{ role_path }}/templates/systemd/matrix-livekit-server.service.j2"
|
||||||
dest: "{{ devture_systemd_docker_base_systemd_path }}/matrix-livekit-server.service"
|
dest: "{{ devture_systemd_docker_base_systemd_path }}/matrix-livekit-server.service"
|
||||||
mode: 0644
|
mode: 0644
|
||||||
|
@ -7,15 +7,15 @@
|
|||||||
- install-all
|
- install-all
|
||||||
- install-livekit-server
|
- install-livekit-server
|
||||||
block:
|
block:
|
||||||
- when: matrix_livekit_server_enabled | bool
|
- when: livekit_server_enabled | bool
|
||||||
ansible.builtin.include_tasks: "{{ role_path }}/tasks/validate_config.yml"
|
ansible.builtin.include_tasks: "{{ role_path }}/tasks/validate_config.yml"
|
||||||
|
|
||||||
- when: matrix_livekit_server_enabled | bool
|
- when: livekit_server_enabled | bool
|
||||||
ansible.builtin.include_tasks: "{{ role_path }}/tasks/install.yml"
|
ansible.builtin.include_tasks: "{{ role_path }}/tasks/install.yml"
|
||||||
|
|
||||||
- tags:
|
- tags:
|
||||||
- setup-all
|
- setup-all
|
||||||
- setup-livekit-server
|
- setup-livekit-server
|
||||||
block:
|
block:
|
||||||
- when: not matrix_livekit_server_enabled | bool
|
- when: not livekit_server_enabled | bool
|
||||||
ansible.builtin.include_tasks: "{{ role_path }}/tasks/uninstall.yml"
|
ansible.builtin.include_tasks: "{{ role_path }}/tasks/uninstall.yml"
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
You need to define a required configuration setting (`{{ item.name }}`).
|
You need to define a required configuration setting (`{{ item.name }}`).
|
||||||
when: "item.when | bool and vars[item.name] == ''"
|
when: "item.when | bool and vars[item.name] == ''"
|
||||||
with_items:
|
with_items:
|
||||||
- {'name': 'matrix_livekit_server_base_path', when: true}
|
- {'name': 'livekit_server_base_path', when: true}
|
||||||
- {'name': 'matrix_livekit_server_container_network', when: true}
|
- {'name': 'livekit_server_container_network', when: true}
|
||||||
- {'name': 'matrix_livekit_server_image', when: true}
|
- {'name': 'livekit_server_image', when: true}
|
||||||
- {'name': 'matrix_livekit_server_image', when: true}
|
- {'name': 'livekit_server_image', when: true}
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
{% if matrix_livekit_server_container_labels_traefik_enabled %}
|
{% if livekit_server_container_labels_traefik_enabled %}
|
||||||
traefik.enable=true
|
traefik.enable=true
|
||||||
|
|
||||||
# Network configuration for Traefik
|
# Network configuration for Traefik
|
||||||
{% if matrix_livekit_server_container_labels_traefik_docker_network %}
|
{% if livekit_server_container_labels_traefik_docker_network %}
|
||||||
traefik.docker.network={{ matrix_livekit_server_container_labels_traefik_docker_network }}
|
traefik.docker.network={{ livekit_server_container_labels_traefik_docker_network }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
traefik.http.services.matrix-livekit-server.loadbalancer.server.port=7880
|
traefik.http.services.matrix-livekit-server.loadbalancer.server.port=7880
|
||||||
@ -11,36 +11,36 @@ traefik.http.services.matrix-livekit-server.loadbalancer.server.port=7880
|
|||||||
{% set middlewares = [] %}
|
{% set middlewares = [] %}
|
||||||
|
|
||||||
# Path prefix handling for Livekit
|
# Path prefix handling for Livekit
|
||||||
{% if matrix_livekit_server_container_labels_traefik_path_prefix != '/' %}
|
{% if livekit_server_container_labels_traefik_path_prefix != '/' %}
|
||||||
traefik.http.middlewares.matrix-livekit-server-slashless-redirect.redirectregex.regex=({{ matrix_livekit_server_container_labels_traefik_path_prefix | quote }})$
|
traefik.http.middlewares.matrix-livekit-server-slashless-redirect.redirectregex.regex=({{ livekit_server_container_labels_traefik_path_prefix | quote }})$
|
||||||
traefik.http.middlewares.matrix-livekit-server-slashless-redirect.redirectregex.replacement=${1}/
|
traefik.http.middlewares.matrix-livekit-server-slashless-redirect.redirectregex.replacement=${1}/
|
||||||
{% set middlewares = middlewares + ['matrix-livekit-server-slashless-redirect'] %}
|
{% set middlewares = middlewares + ['matrix-livekit-server-slashless-redirect'] %}
|
||||||
|
|
||||||
traefik.http.middlewares.matrix-livekit-server-strip-prefix.stripprefix.prefixes={{ matrix_livekit_server_container_labels_traefik_path_prefix }}
|
traefik.http.middlewares.matrix-livekit-server-strip-prefix.stripprefix.prefixes={{ livekit_server_container_labels_traefik_path_prefix }}
|
||||||
{% set middlewares = middlewares + ['matrix-livekit-server-strip-prefix'] %}
|
{% set middlewares = middlewares + ['matrix-livekit-server-strip-prefix'] %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% if matrix_livekit_server_container_labels_traefik_additional_response_headers.keys() | length > 0 %}
|
{% if livekit_server_container_labels_traefik_additional_response_headers.keys() | length > 0 %}
|
||||||
{% for name, value in matrix_livekit_server_container_labels_traefik_additional_response_headers.items() %}
|
{% for name, value in livekit_server_container_labels_traefik_additional_response_headers.items() %}
|
||||||
traefik.http.middlewares.matrix-livekit-server-add-headers.headers.customresponseheaders.{{ name }}={{ value }}
|
traefik.http.middlewares.matrix-livekit-server-add-headers.headers.customresponseheaders.{{ name }}={{ value }}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
{% set middlewares = middlewares + ['matrix-livekit-server-add-headers'] %}
|
{% set middlewares = middlewares + ['matrix-livekit-server-add-headers'] %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
traefik.http.routers.matrix-livekit-server.rule={{ matrix_livekit_server_container_labels_traefik_rule }}
|
traefik.http.routers.matrix-livekit-server.rule={{ livekit_server_container_labels_traefik_rule }}
|
||||||
{% if matrix_livekit_server_container_labels_traefik_priority | int > 0 %}
|
{% if livekit_server_container_labels_traefik_priority | int > 0 %}
|
||||||
traefik.http.routers.matrix-livekit-server.priority={{ matrix_livekit_server_container_labels_traefik_priority }}
|
traefik.http.routers.matrix-livekit-server.priority={{ livekit_server_container_labels_traefik_priority }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
traefik.http.routers.matrix-livekit-server.service=matrix-livekit-server
|
traefik.http.routers.matrix-livekit-server.service=matrix-livekit-server
|
||||||
{% if middlewares | length > 0 %}
|
{% if middlewares | length > 0 %}
|
||||||
traefik.http.routers.matrix-livekit-server.middlewares={{ middlewares | join(',') }}
|
traefik.http.routers.matrix-livekit-server.middlewares={{ middlewares | join(',') }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
traefik.http.routers.matrix-livekit-server.entrypoints={{ matrix_livekit_server_container_labels_traefik_entrypoints }}
|
traefik.http.routers.matrix-livekit-server.entrypoints={{ livekit_server_container_labels_traefik_entrypoints }}
|
||||||
traefik.http.routers.matrix-livekit-server.tls={{ matrix_livekit_server_container_labels_traefik_tls | to_json }}
|
traefik.http.routers.matrix-livekit-server.tls={{ livekit_server_container_labels_traefik_tls | to_json }}
|
||||||
{% if matrix_livekit_server_container_labels_traefik_tls %}
|
{% if livekit_server_container_labels_traefik_tls %}
|
||||||
traefik.http.routers.matrix-livekit-server.tls.certResolver={{ matrix_livekit_server_container_labels_traefik_tls_certResolver }}
|
traefik.http.routers.matrix-livekit-server.tls.certResolver={{ livekit_server_container_labels_traefik_tls_certResolver }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{{ matrix_livekit_server_container_labels_additional_labels }}
|
{{ livekit_server_container_labels_additional_labels }}
|
||||||
|
@ -17,4 +17,4 @@ turn:
|
|||||||
external_tls: true
|
external_tls: true
|
||||||
|
|
||||||
keys:
|
keys:
|
||||||
devkey: "{{ matrix_livekit_server_livekit_dev_key }}"
|
devkey: "{{ livekit_server_livekit_dev_key }}"
|
||||||
|
@ -17,9 +17,9 @@ ExecStartPre={{ devture_systemd_docker_base_host_command_docker }} create \
|
|||||||
--user={{ matrix_user_uid }}:{{ matrix_user_gid }} \
|
--user={{ matrix_user_uid }}:{{ matrix_user_gid }} \
|
||||||
--cap-drop=ALL \
|
--cap-drop=ALL \
|
||||||
--network=host \
|
--network=host \
|
||||||
--mount type=bind,src={{ matrix_livekit_server_base_path }}/livekit.yaml,dst=/etc/livekit.yaml,ro \
|
--mount type=bind,src={{ livekit_server_base_path }}/livekit.yaml,dst=/etc/livekit.yaml,ro \
|
||||||
--label-file={{ matrix_livekit_server_base_path }}/labels \
|
--label-file={{ livekit_server_base_path }}/labels \
|
||||||
{{ matrix_livekit_server_image }} \
|
{{ livekit_server_image }} \
|
||||||
--dev --config /etc/livekit.yaml
|
--dev --config /etc/livekit.yaml
|
||||||
|
|
||||||
ExecStart={{ devture_systemd_docker_base_host_command_docker }} start --attach matrix-livekit-server
|
ExecStart={{ devture_systemd_docker_base_host_command_docker }} start --attach matrix-livekit-server
|
||||||
@ -31,4 +31,4 @@ RestartSec=30
|
|||||||
SyslogIdentifier=matrix-livekit-server
|
SyslogIdentifier=matrix-livekit-server
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
|
Loading…
x
Reference in New Issue
Block a user