You've already forked docker-mailserver
mirror of
https://github.com/docker-mailserver/docker-mailserver.git
synced 2025-08-09 23:07:35 +02:00
Remove code duplication
This commit is contained in:
@@ -31,15 +31,7 @@ setup() {
|
|||||||
-t ${NAME}
|
-t ${NAME}
|
||||||
|
|
||||||
# wait until postfix is up
|
# wait until postfix is up
|
||||||
STARTTIME=$SECONDS
|
repeat_until_success_or_timeout 60 docker exec mail_smtponly_second_network /bin/sh -c "nc -z 0.0.0.0 25"
|
||||||
until docker exec mail_smtponly_second_network /bin/sh -c "nc -z 0.0.0.0 25"
|
|
||||||
do
|
|
||||||
sleep 5
|
|
||||||
if [[ $(($SECONDS - $STARTTIME )) -gt 60 ]]; then
|
|
||||||
echo "Waiting for server timed out after $(($SECONDS - $STARTTIME )) seconds"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
}
|
}
|
||||||
|
|
||||||
teardown() {
|
teardown() {
|
||||||
|
Reference in New Issue
Block a user