1
0
mirror of https://github.com/mail-in-a-box/mailinabox.git synced 2025-04-04 00:17:06 +00:00

Move nsd fix for Travis-CI into setup/dns.sh

This commit is contained in:
downtownallday 2020-06-09 23:20:02 -04:00
parent 81c2b75ee4
commit 4d99e6021b
3 changed files with 20 additions and 18 deletions

View File

@ -62,6 +62,20 @@ for ip in $PRIVATE_IP $PRIVATE_IPV6; do
echo " ip-address: $ip" >> /etc/nsd/nsd.conf;
done
# Deal with a failure for nsd to start on Travis-CI by disabling ip6
# and setting control-enable to "no". Even though the nsd docs say the
# default value for control-enable is no, running "nsd-checkconf -o
# control-enable /etc/nsd/nsd.conf" returns "yes", so we explicitly
# set it here.
if [ -z "$PRIVATE_IPV6" -a "$TRAVIS" == "true" ]; then
cat >> /etc/nsd.conf <<EOF
do-ip4: yes
do-ip6: no
remote-control:
control-enable: no
EOF
fi
echo "include: /etc/nsd/zones.conf" >> /etc/nsd/nsd.conf;
# Create DNSSEC signing keys.

View File

@ -102,22 +102,9 @@ before_miab_install() {
miab_install() {
H1 "MIAB-LDAP INSTALL"
if ! setup/start.sh; then
local failure="true"
if [ "$TRAVIS" == "true" ] && tail -10 /var/log/syslog | grep "Exception on /mail/users/add" >/dev/null; then
dump_log "/etc/mailinabox.conf"
H2 "Apply Travis-CI nsd fix"
travis_fix_nsd || die "Could not fix NSD startup issue"
H2 "Re-run firstuser.sh and mods.d/remote-nextcloud.sh"
if setup/firstuser.sh && setup/mods.d/remote-nextcloud.sh; then
failure="false"
fi
fi
if [ "$failure" == "true" ]; then
dump_log "/var/log/syslog" 100
die "setup/start.sh failed!"
fi
dump_log "/var/log/syslog" 100
dump_log "/etc/mailinabox.conf"
die "setup/start.sh failed!"
fi
}
@ -128,8 +115,8 @@ after_miab_install() {
. /etc/mailinabox.conf || die "Could not load /etc/mailinabox.conf"
# TRAVIS: fix nsd startup problem
H2 "Apply Travis-CI nsd fix"
travis_fix_nsd || die "Could not fix NSD startup issue for TRAVIS-CI"
#H2 "Apply Travis-CI nsd fix"
#travis_fix_nsd || die "Could not fix NSD startup issue for TRAVIS-CI"
# run Nextcloud docker image
H2 "Start Nextcloud docker container"

View File

@ -28,6 +28,7 @@ dump_log() {
H1 "$title"
cat "$log_file"
fi
H1 "END $title"
}
install_qa_prerequisites() {