Page Menu
Home
GRNET
Search
Configure Global Search
Log In
Files
F1615255
entrypoint.sh
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Sat, Mar 21, 10:07 PM
Size
682 B
Mime Type
text/x-shellscript
Expires
Mon, Mar 23, 10:07 PM (1 d, 1 h)
Engine
blob
Format
Raw Data
Handle
354337
Attached To
rDOCKERWEBDNS webdns_docker
entrypoint.sh
View Options
#!/bin/bash
if
[
-z
"
${
MYSQL_HOST
}
"
]
;
then
echo
"You need to specify a MySQL host."
exit
fi
MYSQL_DATABASE
=
${
MYSQL_DATABASE
-dns
}
MYSQL_USER
=
${
MYSQL_USER
-dns
}
MYSQL_PORT
=
${
MYSQL_PORT
-3306
}
MYSQL_PASSWORD
=
${
MYSQL_PASSWORD
-12345
}
echo
"Settings up pdns config."
cat
<<EOF > /etc/powerdns/pdns.d/pdns.local.gmysql.conf
# MySQL Configuration
launch+=gmysql
# gmysql parameters
gmysql-host=${MYSQL_HOST}
gmysql-port=3306
gmysql-dbname=${MYSQL_DATABASE}
gmysql-user=${MYSQL_USER}
gmysql-password=${MYSQL_PASSWORD}
gmysql-dnssec=no
EOF
echo
"Waiting for the db to come up and webdns to run initial migration."
sleep 10
echo
"Starting powerdns"
/usr/sbin/pdns_server --daemon
=
no
Event Timeline
Log In to Comment