diff --git a/bind/entrypoint.sh b/bind/entrypoint.sh index c7952d8..2be152f 100755 --- a/bind/entrypoint.sh +++ b/bind/entrypoint.sh @@ -3,9 +3,9 @@ # $ dnssec-keygen -K /etc/bind -a RSASHA256 -b 4096 -n ZONE -3 -f KSK $DOMAIN # $ dnssec-keygen -K /etc/bind -a RSASHA256 -b 2048 -n ZONE $DOMAIN # $ opendkim-genkey -b 2048 -h rsa-sha256 -r -s dkim -d $DOMAIN -v -DOMAIN="DOMAIN.COM" -IP=MACHINE-IPV4 -IPV6=MACHINE-IPV6 +DOMAIN=$DOMAIN +IP=$IP +IPV6=$IPV6 DKIM=$(sed -e 's/"/\"/g' /etc/bind/dkim.txt) if [ $(cat /etc/bind/version) -gt 99 ] || [ ! -e /etc/bind/version ]; then echo 1 > /etc/bind/version diff --git a/docker-compose.yml b/docker-compose.yml index 51e9ffa..b052d29 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -6,6 +6,8 @@ services: hostname: bind container_name: bind restart: always + env_file: + - env entrypoint: - /etc/bind/entrypoint.sh ports: diff --git a/env b/env new file mode 100644 index 0000000..66ccb7f --- /dev/null +++ b/env @@ -0,0 +1,3 @@ +DOMAIN="DOMAIN.COM" +IP=MACHINE-IPV4 +IPV6=MACHINE-IPV6