alpine approach completed
This commit is contained in:
parent
9f65b7690e
commit
f205858c30
@ -12,10 +12,14 @@ ENV RELAYNETS=""
|
|||||||
|
|
||||||
RUN apk add --no-cache exim bash
|
RUN apk add --no-cache exim bash
|
||||||
|
|
||||||
|
COPY exim.conf.tmpl /etc/exim
|
||||||
|
COPY start.sh /etc/exim
|
||||||
|
|
||||||
WORKDIR /etc/exim
|
WORKDIR /etc/exim
|
||||||
|
|
||||||
EXPOSE 25
|
EXPOSE 25
|
||||||
|
|
||||||
|
CMD [ "./start.sh" ]
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,15 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
cat update-exim4.conf.tmpl \
|
|
||||||
| sed -e 's/%HOSTNAME%/'$HOSTNAME'/' \
|
|
||||||
-e 's#%RELAYNETS%#'$RELAYNETS'#' \
|
|
||||||
-e 's/%LOCALMAILNAME%/'$LOCALMAILNAME'/' \
|
|
||||||
-e 's/%SMARTHOST%/'$SMARTHOST'/' \
|
|
||||||
> update-exim4.conf.conf
|
|
||||||
cat aliases.tmpl \
|
|
||||||
| sed -e 's/%ROOT%/'"$ROOT"'/' \
|
|
||||||
> ../aliases && \
|
|
||||||
newaliases
|
|
||||||
|
|
||||||
/usr/sbin/update-exim4.conf -v
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
|||||||
primary_hostname = mail.hottis.de
|
primary_hostname = %HOSTNAME%
|
||||||
qualify_domain = hottis.de
|
qualify_domain = %LOCALMAILNAME%
|
||||||
|
|
||||||
acl_smtp_rcpt = acl_check_rcpt
|
acl_smtp_rcpt = acl_check_rcpt
|
||||||
|
|
||||||
@ -8,7 +8,7 @@ smarthost_route:
|
|||||||
driver = manualroute
|
driver = manualroute
|
||||||
domains = *
|
domains = *
|
||||||
transport = smarthost_smtp
|
transport = smarthost_smtp
|
||||||
route_list = * mail.bighost.com
|
route_list = * %SMARTHOST%
|
||||||
|
|
||||||
begin transports
|
begin transports
|
||||||
smarthost_smtp:
|
smarthost_smtp:
|
||||||
@ -19,10 +19,10 @@ smarthost_smtp:
|
|||||||
begin acl
|
begin acl
|
||||||
acl_check_rcpt:
|
acl_check_rcpt:
|
||||||
accept
|
accept
|
||||||
hosts = 172.17.0.0/16 : 172.16.3.0/24
|
hosts = %RELAYNETS%
|
||||||
deny
|
deny
|
||||||
message = "Relaying denied"
|
message = "Relaying denied"
|
||||||
|
|
||||||
begin rewrite
|
begin rewrite
|
||||||
*@* ${expand:${1}@${qualify_domain}}
|
*@* ${1}@${qualify_domain} Ffrs
|
||||||
|
|
12
start.sh
12
start.sh
@ -1,5 +1,13 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
./adjust-config.sh
|
rm exim.conf
|
||||||
exim -bd -q15m
|
|
||||||
|
cat exim.conf.tmpl \
|
||||||
|
| sed -e 's/%HOSTNAME%/'$HOSTNAME'/' \
|
||||||
|
-e 's#%RELAYNETS%#'$RELAYNETS'#' \
|
||||||
|
-e 's/%LOCALMAILNAME%/'$LOCALMAILNAME'/' \
|
||||||
|
-e 's/%SMARTHOST%/'$SMARTHOST'/' \
|
||||||
|
> exim.conf
|
||||||
|
|
||||||
|
exim -bd -q15m -v
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user