StackFocus.postmaster
PostMaster Ansible Role
This Ansible role helps you install the web application PostMaster, created by StackFocus.
Requirements
To use this role, you need version 2.4.2 of the geerlingguy.mysql Ansible role. If you install this role via Ansible Galaxy, geerlingguy.mysql will be installed automatically. Note: The geerlingguy.mysql role is only needed if you set postmaster_install_mysql
to True
.
This role must be run with sudo or as the root user; otherwise, it won’t work.
Role Variables:
- postmaster_db_user: MySQL user for PostMaster to connect.
- postmaster_db_password: Password for the MySQL user.
- postmaster_db_host: Hostname or IP address of the MySQL server (default is
localhost
). - postmaster_db_port: Port for the MySQL server (default is
3306
). - postmaster_db_name: Name of the MySQL database (default is
servermail
). - postmaster_secret_key: Secret key for Flask used by PostMaster (should be a random string).
- postmaster_migrate_db: Whether to upgrade the PostMaster database (defaults to
True
). - postmaster_install_mysql: Whether to install MySQL with the geerlingguy.mysql role (defaults to
False
). Check that role's documentation for MySQL setup options. - postmaster_apache_vhost_extra_settings: Any extra Apache settings for the PostMaster VirtualHost (not set by default).
- postmaster_apache_port: Port for the PostMaster virtual host.
- postmaster_apache_ssl_cert: Path to the SSL certificate on the target node for the PostMaster virtual host. No SSL will be used if not set.
- postmaster_apache_ssl_key: Path to the SSL key on the target node for the PostMaster virtual host. No SSL will be used if not set.
- postmaster_apache_ssl_chain: Path to the SSL certificate chain on the target node for the PostMaster virtual host. Not required for SSL but needed if
postmaster_apache_ssl_local_chain
is set. - postmaster_apache_ssl_local_cert: Local path to copy the SSL certificate to the path in
postmaster_apache_ssl_cert
. Not required. - postmaster_apache_ssl_local_key: Local path to copy the SSL key to the path in
postmaster_apache_ssl_key
. Not required. - postmaster_apache_ssl_local_chain: Local path to copy the SSL certificate chain to the path in
postmaster_apache_ssl_chain
. Not required. - postmaster_apache_ssl_cipher_suite: SSL cipher suite allowed by the PostMaster virtual host (defaults to
AES256+EECDH:AES256+EDH
). - postmaster_apache_ssl_protocol: SSL protocols allowed by the PostMaster virtual host (defaults to
All -SSLv2 -SSLv3
). - postmaster_clean_virtualenv: Delete and recreate the PostMaster virtual environment, useful for cleaning up old Python dependencies after upgrades (defaults to
False
).
Playbook Example:
- name: Deploy PostMaster
hosts: mailserver
become: yes
vars:
- postmaster_db_user: postmaster_user
- postmaster_db_password: DbUserPassword
- postmaster_db_host: localhost
- postmaster_db_name: servermail
- postmaster_migrate_db: True
- postmaster_secret_key: SuperSecretKey
- postmaster_apache_port: 8443
- postmaster_apache_ssl_cert: /local/path/to/postmaster.crt
- postmaster_apache_ssl_key: /local/path/to/postmaster.key
- postmaster_install_mysql: True
- mysql_root_password: MySqlRootPassword
- mysql_enabled_on_startup: yes
- mysql_databases:
- name: "{{ postmaster_db_name }}"
- mysql_users:
- name: "{{ postmaster_db_user }}"
password: "{{ postmaster_db_password }}"
host: localhost
priv: "{{ postmaster_db_name }}.*:ALL"
roles:
- postmaster
Installa
ansible-galaxy install StackFocus.postmaster
Licenza
Unknown
Download
30.4k
Proprietario