mirror of
https://github.com/spantaleev/matrix-docker-ansible-deploy.git
synced 2026-04-09 10:25:38 +00:00
Upgrade baibot (v1.14.3 -> v1.15.0) and adapt to support optional access-token auth mode
Ref: - https://github.com/etkecc/baibot/pull/83 -748d2b7fd4/CHANGELOG.md (2026-03-07-version-1150)-748d2b7fd4/docs/configuration/authentication.md
This commit is contained in:
@@ -12,7 +12,6 @@
|
||||
when: "item.when | bool and lookup('vars', item.name, default='') | string | length == 0"
|
||||
with_items:
|
||||
- {'name': 'matrix_bot_baibot_config_user_mxid_localpart', when: true}
|
||||
- {'name': 'matrix_bot_baibot_config_user_password', when: true}
|
||||
- {'name': 'matrix_bot_baibot_container_network', when: true}
|
||||
- {'name': 'matrix_bot_baibot_config_homeserver_url', when: true}
|
||||
|
||||
@@ -26,6 +25,58 @@
|
||||
|
||||
- {'name': 'matrix_bot_baibot_config_agents_static_definitions_openai_config_api_key', when: "{{ matrix_bot_baibot_config_agents_static_definitions_openai_enabled }}"}
|
||||
|
||||
- name: Fail if baibot authentication mode is not configured
|
||||
ansible.builtin.fail:
|
||||
msg: >-
|
||||
You need to configure one baibot authentication mode:
|
||||
either `matrix_bot_baibot_config_user_password`
|
||||
or (`matrix_bot_baibot_config_user_access_token` + `matrix_bot_baibot_config_user_device_id`).
|
||||
when: >-
|
||||
(
|
||||
matrix_bot_baibot_config_user_password | default('', true) | string | length == 0
|
||||
)
|
||||
and
|
||||
(
|
||||
matrix_bot_baibot_config_user_access_token | default('', true) | string | length == 0
|
||||
and matrix_bot_baibot_config_user_device_id | default('', true) | string | length == 0
|
||||
)
|
||||
|
||||
- name: Fail if baibot authentication mode is configured ambiguously
|
||||
ansible.builtin.fail:
|
||||
msg: >-
|
||||
You need to configure exactly one baibot authentication mode.
|
||||
Set either `matrix_bot_baibot_config_user_password`,
|
||||
or (`matrix_bot_baibot_config_user_access_token` + `matrix_bot_baibot_config_user_device_id`) but not both.
|
||||
when: >-
|
||||
(
|
||||
matrix_bot_baibot_config_user_password | default('', true) | string | length > 0
|
||||
)
|
||||
and
|
||||
(
|
||||
matrix_bot_baibot_config_user_access_token | default('', true) | string | length > 0
|
||||
or matrix_bot_baibot_config_user_device_id | default('', true) | string | length > 0
|
||||
)
|
||||
|
||||
- name: Fail if baibot access token authentication is incomplete
|
||||
ansible.builtin.fail:
|
||||
msg: >-
|
||||
Access-token authentication requires both
|
||||
`matrix_bot_baibot_config_user_access_token` and `matrix_bot_baibot_config_user_device_id`.
|
||||
when: >-
|
||||
(
|
||||
matrix_bot_baibot_config_user_password | default('', true) | string | length == 0
|
||||
)
|
||||
and
|
||||
(
|
||||
matrix_bot_baibot_config_user_access_token | default('', true) | string | length > 0
|
||||
or matrix_bot_baibot_config_user_device_id | default('', true) | string | length > 0
|
||||
)
|
||||
and
|
||||
(
|
||||
matrix_bot_baibot_config_user_access_token | default('', true) | string | length == 0
|
||||
or matrix_bot_baibot_config_user_device_id | default('', true) | string | length == 0
|
||||
)
|
||||
|
||||
- name: Fail if admin patterns list is empty
|
||||
ansible.builtin.fail:
|
||||
msg: >-
|
||||
|
||||
Reference in New Issue
Block a user