prosody/tasks/main.yaml
author Luke Hoersten <luke@hoersten.org>
Thu, 14 May 2020 08:25:10 -0500
changeset 23 b4ad03deace1
child 44 aaf10cecfc1f
permissions -rw-r--r--
Added prosody role.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
23
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
     1
---
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
     2
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
     3
- name: install prosody
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
     4
  become: yes
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
     5
  apt: name="prosody"
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
     6
  notify: restart prosody
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
     7
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
     8
- name: configure prosody
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
     9
  become: yes
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    10
  template:
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    11
    src: "prosody.cfg.lua.j2"
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    12
    dest: "/etc/prosody/conf.avail/{{prosody_vhost}}.cfg.lua"
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    13
  notify: restart prosody
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    14
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    15
- name: install prosody site
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    16
  become: yes
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    17
  template: src="prosody.cfg.lua.j2" dest="/etc/prosody/conf.avail/{{prosody_vhost}}.cfg.lua"
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    18
  notify: restart prosody
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    19
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    20
- name: enable prosody site
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    21
  become: yes
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    22
  file:
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    23
    src:  "/etc/prosody/conf.avail/{{prosody_vhost}}.cfg.lua"
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    24
    dest: "/etc/prosody/conf.d/{{prosody_vhost}}.cfg.lua"
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    25
    state: "link"
b4ad03deace1 Added prosody role.
Luke Hoersten <luke@hoersten.org>
parents:
diff changeset
    26
  notify: restart prosody