Enable selecting the TLS Certificate
This commit is contained in:
		| @@ -82,6 +82,7 @@ Role Variables | |||||||
| | dovecot_mysql_database | undefined | Database with MySQL to use | | | dovecot_mysql_database | undefined | Database with MySQL to use | | ||||||
| | dovecot_mysql_username | undefined | Username with read only rights | | | dovecot_mysql_username | undefined | Username with read only rights | | ||||||
| | dovecot_mysql_password | undefined | Password for read only user | | | dovecot_mysql_password | undefined | Password for read only user | | ||||||
|  | | dovecot_vhost | inventory_hostname | What mod_md certificate should be used for Dovecot | | ||||||
|  |  | ||||||
| Dependencies | Dependencies | ||||||
| ------------ | ------------ | ||||||
|   | |||||||
| @@ -1,2 +1,3 @@ | |||||||
| --- | --- | ||||||
| # defaults file for ensure_dovecot | # defaults file for ensure_dovecot | ||||||
|  | dovecot_vhost: '{{ inventory_hostname }}' | ||||||
|   | |||||||
| @@ -4,7 +4,7 @@ Description=Copy TLS Certificates for Dovecot | |||||||
| [Service] | [Service] | ||||||
| Type=oneshot | Type=oneshot | ||||||
| ExecStartPre=mkdir -p /etc/dovecot/certificates | ExecStartPre=mkdir -p /etc/dovecot/certificates | ||||||
| ExecStart=/bin/bash -lc 'cp /etc/httpd/md/domains/*/*.pem /etc/dovecot/certificates/' | ExecStart=/bin/bash -lc 'cp /etc/httpd/md/domains/{{ dovecot_vhost }}/*.pem /etc/dovecot/certificates/' | ||||||
| ExecStartPost=chown -R root:root /etc/dovecot/certificates | ExecStartPost=chown -R root:root /etc/dovecot/certificates | ||||||
|  |  | ||||||
| [Install] | [Install] | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user