[Unit] Description=Copy TLS Certificates for Dovecot [Service] Type=oneshot ExecStartPre=mkdir -p /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 [Install] WantedBy=dovecot.service