浏览代码

Add support for matrix-synapse-shared-secret-auth

pull/6/head
Slavi Pantaleev 7 年前
父节点
当前提交
14d7d3e670
共有 5 个文件被更改,包括 27 次插入2 次删除
  1. +1
    -1
      docs/configuring-playbook-rest-auth.md
  2. +12
    -0
      docs/configuring-playbook-shared-secret-auth.md
  3. +3
    -1
      docs/configuring-playbook.md
  4. +6
    -0
      roles/matrix-server/defaults/main.yml
  5. +5
    -0
      roles/matrix-server/tasks/setup_synapse_ext_shared_secret_auth.yml

+ 1
- 1
docs/configuring-playbook-rest-auth.md 查看文件

@@ -1,6 +1,6 @@
# Setting up the REST authentication password provider module

The playbook can now install and configure [matrix-synapse-rest-auth](https://github.com/kamax-io/matrix-synapse-rest-auth) for you.
The playbook can install and configure [matrix-synapse-rest-auth](https://github.com/kamax-io/matrix-synapse-rest-auth) for you.

See that project's documentation to learn what it does and why it might be useful to you.



+ 12
- 0
docs/configuring-playbook-shared-secret-auth.md 查看文件

@@ -0,0 +1,12 @@
# Setting up the Shared Secret Auth password provider module

The playbook can install and configure [matrix-synapse-shared-secret-auth](https://github.com/devture/matrix-synapse-shared-secret-auth) for you.

See that project's documentation to learn what it does and why it might be useful to you.

If you decide that you'd like to let this playbook install it for you, you need some configuration like this:

```yaml
matrix_synapse_ext_password_provider_shared_secret_auth_enabled: true
matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret: YOUR_SHARED_SECRET_GOES_HERE
```

+ 3
- 1
docs/configuring-playbook.md 查看文件

@@ -33,4 +33,6 @@ When you're done with all the configuration you'd like to do, continue with [Ins

- [Using your own webserver, instead of this playbook's nginx proxy](configuring-playbook-own-webserver.md) (optional)

- [Setting up the REST authentication password provider module](configuring-playbook-rest-auth.md) (optional)
- [Setting up the REST authentication password provider module](configuring-playbook-rest-auth.md) (optional)

- [Setting up the Shared Secret Auth password provider module](configuring-playbook-shared-secret-auth.md) (optional)

+ 6
- 0
roles/matrix-server/defaults/main.yml 查看文件

@@ -84,6 +84,12 @@ matrix_synapse_ext_password_provider_rest_auth_registration_enforce_lowercase: f
matrix_synapse_ext_password_provider_rest_auth_registration_profile_name_autofill: true
matrix_synapse_ext_password_provider_rest_auth_login_profile_name_autofill: false

# Enable this to activate the Shared Secret Auth password provider module.
# See: https://github.com/devture/matrix-synapse-shared-secret-auth
matrix_synapse_ext_password_provider_shared_secret_auth_enabled: false
matrix_synapse_ext_password_provider_shared_secret_auth_download_url: "https://raw.githubusercontent.com/devture/matrix-synapse-shared-secret-auth/1.0/shared_secret_authenticator.py"
matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret: ""

matrix_postgres_data_path: "{{ matrix_base_data_path }}/postgres"
matrix_nginx_proxy_data_path: "{{ matrix_base_data_path }}/nginx-proxy"
matrix_nginx_proxy_confd_path: "{{ matrix_nginx_proxy_data_path }}/conf.d"


+ 5
- 0
roles/matrix-server/tasks/setup_synapse_ext_shared_secret_auth.yml 查看文件

@@ -4,6 +4,11 @@
# Tasks related to setting up matrix-synapse-shared-secret-auth
#

- name: Fail if Shared Secret Auth enabled, but no secret set
fail:
msg: "Shared Secret Auth is enabled, but no secret has been set in matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret"
when: "matrix_synapse_ext_password_provider_shared_secret_auth_enabled and matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret == ''"

- name: Download matrix-synapse-shared-secret-auth
get_url:
url: "{{ matrix_synapse_ext_password_provider_shared_secret_auth_download_url }}"


正在加载...
取消
保存