Update setup-powerdns.sh

This commit is contained in:
2019-03-30 16:28:20 -05:00
parent 8b08b4c636
commit 7401405ba4

View File

@@ -19,9 +19,6 @@ do
--mysql-password=*)
pass=`echo ${i#*=}`
;;
--virt-serverip=*)
master=`echo ${i#*=}`
;;
--masterns-ip=*)
primarynsip=`echo ${i#*=}`
;;
@@ -43,10 +40,6 @@ if [ ! -n "$pass" ]; then
echo "Please enter the --mysql-password parameter"
exit 1
fi
if [ ! -n "$master" ]; then
echo "Please enter the --virt-serverip parameter"
exit 1
fi
if [ ! -n "$primarynsip" ]; then
echo "Please enter the --masterns-ip parameter"
exit 1
@@ -132,7 +125,7 @@ sed -i "$conf" /etc/pdns/pdns.conf
###################################################################
echo "5) Setting permissions..."
mysql --user $user --password=$pass << eof
GRANT ALL ON powerdns.* TO '$user'@'$master' IDENTIFIED BY '$pass';
GRANT ALL ON *.* TO 'admin'@'%' IDENTIFIED BY 'Dc$@1910' WITH GRANT OPTION;
eof