diff options
author | Quentin <quentin@deuxfleurs.fr> | 2020-09-13 12:03:07 +0200 |
---|---|---|
committer | Quentin <quentin@deuxfleurs.fr> | 2020-09-13 12:03:07 +0200 |
commit | 484c3fe667cd8c5a647256cb78f05c8a39b835b1 (patch) | |
tree | 7be3c868ce1d0e0c96125a4c94cadce429be9e1d /docker/postfix | |
parent | 0550647b9348d1e36431400e0832b4340564c658 (diff) | |
parent | d5bfc38fe826aa12f46de64790195cc8e76756de (diff) | |
download | infrastructure-484c3fe667cd8c5a647256cb78f05c8a39b835b1.tar.gz infrastructure-484c3fe667cd8c5a647256cb78f05c8a39b835b1.zip |
Merge branch 'feature/rebase'
Diffstat (limited to 'docker/postfix')
-rw-r--r-- | docker/postfix/Dockerfile | 11 | ||||
-rw-r--r-- | docker/postfix/README.md | 18 | ||||
-rwxr-xr-x | docker/postfix/entrypoint.sh | 30 |
3 files changed, 0 insertions, 59 deletions
diff --git a/docker/postfix/Dockerfile b/docker/postfix/Dockerfile deleted file mode 100644 index 9e4c067..0000000 --- a/docker/postfix/Dockerfile +++ /dev/null @@ -1,11 +0,0 @@ -FROM amd64/debian:buster - -RUN apt-get update && \ - apt-get install -y \ - postfix \ - postfix-ldap - -COPY entrypoint.sh /usr/local/bin/entrypoint - -ENTRYPOINT ["/usr/local/bin/entrypoint"] -CMD ["postfix", "start-fg"] diff --git a/docker/postfix/README.md b/docker/postfix/README.md deleted file mode 100644 index ac44fc0..0000000 --- a/docker/postfix/README.md +++ /dev/null @@ -1,18 +0,0 @@ -``` -sudo docker build -t superboum/amd64_postfix:v1 . -``` - -``` -sudo docker run -t -i \ - -e TLSINFO="/C=FR/ST=Bretagne/L=Rennes/O=Deuxfleurs/CN=smtp.deuxfleurs.fr" \ - -e MAILNAME="smtp.deuxfleurs.fr" \ - -p 25:25 \ - -p 465:465 \ - -p 587:587 \ - -v `pwd`/../../ansible/roles/container_conf/files/email/postfix-conf:/etc/postfix-conf \ - -v /mnt/glusterfs/email/postfix-ssl/private:/etc/ssl/private \ - -v /mnt/glusterfs/email/postfix-ssl/certs:/etc/ssl/certs \ - superboum/amd64_postfix:v1 \ - bash -``` - diff --git a/docker/postfix/entrypoint.sh b/docker/postfix/entrypoint.sh deleted file mode 100755 index c7ace3d..0000000 --- a/docker/postfix/entrypoint.sh +++ /dev/null @@ -1,30 +0,0 @@ -#!/bin/bash - -if [[ ! -f /etc/ssl/certs/postfix.crt || ! -f /etc/ssl/private/postfix.key ]]; then - cd /root - openssl req \ - -new \ - -newkey rsa:4096 \ - -days 3650 \ - -nodes \ - -x509 \ - -subj ${TLSINFO} \ - -keyout postfix.key \ - -out postfix.crt - - mkdir -p /etc/ssl/{certs,private}/ - - cp postfix.crt /etc/ssl/certs/postfix.crt - cp postfix.key /etc/ssl/private/postfix.key - chmod 400 /etc/ssl/certs/postfix.crt - chmod 400 /etc/ssl/private/postfix.key -fi - -# A way to map files inside the postfix folder :s -for file in $(ls /etc/postfix-conf); do - cp /etc/postfix-conf/${file} /etc/postfix/${file} -done - -echo ${MAILNAME} > /etc/mailname - -exec "$@" |