Explorar el Código

added more docs and timeout value

pull/514/head
benkuly hace 5 años
padre
commit
0b7d6744bf
Se han modificado 3 ficheros con 10 adiciones y 1 borrados
  1. +6
    -0
      docs/configuring-playbook-matrix-sms-bridge.md
  2. +3
    -0
      roles/matrix-sms-bridge/defaults/main.yml
  3. +1
    -1
      roles/matrix-sms-bridge/templates/systemd/matrix-sms-bridge.service.j2

+ 6
- 0
docs/configuring-playbook-matrix-sms-bridge.md Ver fichero

@@ -5,6 +5,8 @@ The playbook can install and configure


See the project page to learn what it does and why it might be useful to you. See the project page to learn what it does and why it might be useful to you.


First you need to ensure, that the bridge has unix read and write rights to your modem. On debian based distributions there is nothing to do. On others distributions you either add a group `dialout` to your host and assign it to your modem or you give the matrix user or group access to your modem.

To enable the bridge just use the following To enable the bridge just use the following
playbook configuration: playbook configuration:


@@ -16,6 +18,10 @@ matrix_sms_bridge_gammu_modem: "/path/to/modem"
matrix_sms_bridge_database_password: "" matrix_sms_bridge_database_password: ""
# (optional) a room id to a default room # (optional) a room id to a default room
matrix_sms_bridge_default_room: "" matrix_sms_bridge_default_room: ""
# (optional) gammu reset frequency (see https://wammu.eu/docs/manual/smsd/config.html#option-ResetFrequency)
matrix_sms_bridge_gammu_reset_frequency: 3600
# (optional) group with unix read and write rights to modem
matrix_sms_bridge_modem_group: 'dialout'
``` ```






+ 3
- 0
roles/matrix-sms-bridge/defaults/main.yml Ver fichero

@@ -48,6 +48,8 @@ matrix_sms_bridge_homserver_domain: "{{ matrix_domain }}"
matrix_sms_bridge_default_room: '' matrix_sms_bridge_default_room: ''


matrix_sms_bridge_gammu_modem: '' matrix_sms_bridge_gammu_modem: ''
matrix_sms_bridge_modem_group: 'dialout'
matrix_sms_bridge_gammu_reset_frequency: 0




matrix_sms_bridge_configuration_yaml: | matrix_sms_bridge_configuration_yaml: |
@@ -122,6 +124,7 @@ matrix_sms_bridge_gammu_configuration: |
InboxFormat = detail InboxFormat = detail
OutboxFormat = detail OutboxFormat = detail
TransmitFormat = auto TransmitFormat = auto
ResetFrequency = {{ matrix_sms_bridge_gammu_reset_frequency }}
debugLevel = 1 debugLevel = 1
LogFile = /data/log/smsd.log LogFile = /data/log/smsd.log
DeliveryReport = log DeliveryReport = log


+ 1
- 1
roles/matrix-sms-bridge/templates/systemd/matrix-sms-bridge.service.j2 Ver fichero

@@ -20,7 +20,7 @@ ExecStartPre=/bin/sleep 5
ExecStart=/usr/bin/docker run --rm --name matrix-sms-bridge \ ExecStart=/usr/bin/docker run --rm --name matrix-sms-bridge \
--log-driver=none \ --log-driver=none \
--user={{ matrix_user_uid }}:{{ matrix_user_gid }} \ --user={{ matrix_user_uid }}:{{ matrix_user_gid }} \
--group-add dialout \
--group-add {{ matrix_sms_bridge_modem_group }} \
--cap-drop=ALL \ --cap-drop=ALL \
--network={{ matrix_docker_network }} \ --network={{ matrix_docker_network }} \
{% if matrix_sms_bridge_container_http_host_bind_port %} {% if matrix_sms_bridge_container_http_host_bind_port %}


Cargando…
Cancelar
Guardar