Added a way to generate and configure a specific SSL certificate for postfix #14

This commit is contained in:
Thomas VIAL 2015-08-18 13:13:08 +02:00
parent 63a7be0e97
commit a848a55177
6 changed files with 37 additions and 4 deletions

View file

@ -61,6 +61,24 @@ Volumes allow to:
docker-compose up -d mail
# configure ssl
## generate ssl certificate
You can easily generate en SSL certificate by using the following command:
docker run -ti --rm -v "$(pwd)"/postfix/ssl:/ssl -h mail.my-domain.com -t tvial/docker-mailserver generate-ssl-certificate
# will generate:
# postfix/ssl/mail.my-domain.com.key
# postfix/ssl/mail.my-domain.com.csr
Note that the certificate will be generate for the container `fqdn`, that is passed as `-h` argument.
## configure ssl certificate (convention over configuration)
If a matching certificate (with `.key` and `.csr` files) is found in `postfix/ssl`, it will be automatically configured in postfix. You just have to place `mail.my-domain.com.key` and `mail.my-domain.com.csr` for domain `mail.my-domain.com` in `postfix/ssl` folder.
# client configuration
# imap