No Description
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

prosody.yml 1.1KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. - name: Ensure repository key for Prosody is in place
  2. apt_key: url=https://prosody.im/files/prosody-debian-packages.key state=present
  3. tags:
  4. - dependencies
  5. - name: Add Prosody repository
  6. apt_repository: repo="deb http://packages.prosody.im/debian {{ ansible_distribution_release }} main"
  7. tags:
  8. - dependencies
  9. - name: Install Prosody and dependencies from official repository
  10. apt: pkg={{ item }} update_cache=yes
  11. with_items:
  12. - prosody
  13. - lua-sec
  14. tags:
  15. - dependencies
  16. - name: Add prosody user to ssl-cert group
  17. user: name=prosody group=ssl-cert
  18. - name: Create Prosody data directory
  19. file: state=directory path=/decrypted/prosody owner=prosody group=prosody
  20. - name: Configure Prosody
  21. template: src=prosody.cfg.lua.j2 dest=/etc/prosody/prosody.cfg.lua group=root owner=root
  22. notify: restart prosody
  23. - name: Create Prosody accounts
  24. command: prosodyctl register {{ item.name }} {{ prosody_virtual_domain }} "{{ item.password }}"
  25. with_items: "{{ prosody_accounts }}"
  26. - name: Set firewall rules for Prosody
  27. ufw: rule=allow port={{ item }} proto=tcp
  28. with_items:
  29. - 5222 # xmpp c2s
  30. - 5269 # xmpp s2s
  31. tags: ufw