Ver código fonte

Add coturn playbook

master
Dryusdan 2 meses atrás
pai
commit
4d366fd67a
3 arquivos alterados com 36 adições e 0 exclusões
  1. +28
    -0
      roles/coturn/tasks/main.yml
  2. +1
    -0
      roles/coturn/templates/coturn.j2
  3. +7
    -0
      roles/coturn/templates/turnserver.conf.j2

+ 28
- 0
roles/coturn/tasks/main.yml Ver arquivo

@@ -0,0 +1,28 @@
---
- name: Install coturn
apt:
name: "{{ packages }}"
vars:
packages:
- coturn

- name: Set template
template:
src: turnserver.conf.j2
dest: /etc/turnserver.conf
owner: root
group: root
mode: 0644

- name: Set template
template:
src: coturn.j2
dest: /etc/default/coturn
owner: root
group: root
mode: 0644

- name: Start servic if not started
service:
name: coturn
state: restarted

+ 1
- 0
roles/coturn/templates/coturn.j2 Ver arquivo

@@ -0,0 +1 @@
TURNSERVER_ENABLED=1

+ 7
- 0
roles/coturn/templates/turnserver.conf.j2 Ver arquivo

@@ -0,0 +1,7 @@
# Full conf : https://github.com/coturn/coturn/blob/master/examples/etc/turnserver.conf
listening-port={{ coturn.listening_port }}
use-auth-secret
static-auth-secret={{ coturn.static_auth_secret }}
server-name={{ coturn.server_name }}
realm={{ coturn.realm }}


Carregando…
Cancelar
Salvar