diff options
-rw-r--r-- | Dockerfile | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -46,6 +46,18 @@ RUN apt update \ sudo \ && apt clean +# Generate OpenDKIM keypair +# Do this here so we can print the pubkey/dns record to logs during build +# process. After initial run, a volume should preserve the keys for later +# runs. +RUN mkdir -p /opendkim \ + && chown opendkim:opendkim /opendkim \ + && opendkim-genkey \ + --bits=1024 \ + --directory=/opendkim \ + --selector=default \ + && cat /opendkim/default.txt + # Install files COPY dovecot /etc/dovecot/ COPY opendkim /etc/ |