-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathscript_init.sh
More file actions
37 lines (29 loc) · 1.11 KB
/
script_init.sh
File metadata and controls
37 lines (29 loc) · 1.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#!/bin/bash
set -euxo pipefail
export DEBIAN_FRONTEND=noninteractive
rm -rf /etc/apt/apt.conf.d/docker-gzip-indexes
apt-get -yq update < /dev/null
apt-get -yq upgrade < /dev/null
apt-get -yq install apt-utils gnupg2 < /dev/null
apt-get -yq install apt-transport-https ca-certificates net-tools unzip wget < /dev/null
apt-get -yq install perl libnet-ssleay-perl openssl libauthen-pam-perl libpam-runtime libio-pty-perl apt-show-versions python < /dev/null
apt-get -yq install bind9 bind9utils bind9-host < /dev/null
echo "deb https://download.webmin.com/download/repository sarge contrib" >> /etc/apt/sources.list
wget -qO- http://www.webmin.com/jcameron-key.asc | apt-key add -
apt-get -yq update < /dev/null
apt-get -yq install webmin < /dev/null
mkdir -m 0775 -p /var/run/named
chown root:bind /var/run/named
mkdir -m 0775 -p /var/cache/bind
chown root:bind /var/cache/bind
rm -rf /var/lib/apt/lists/*
cat > /etc/bind/named.conf.options <<'EOL'
options {
directory "/var/cache/bind";
dnssec-validation auto;
auth-nxdomain no; # conform to RFC1035
listen-on-v6 { any; };
recursion no;
allow-transfer { none; };
};
EOL