This commit is contained in:
Radar231 2023-09-11 06:30:42 -04:00
parent e72d20b979
commit 912da5c22c
1 changed files with 4 additions and 3 deletions

View File

@ -1,10 +1,11 @@
#!/bin/bash
# pihole server to sync from
syncsvr='192.168.7.21'
syncsvr='192.168.20.21'
srcsvr='pihole1'
dstsvr='pihole2'
filepath='/opt/docker/docker_pihole'
srcpath='/opt/docker/docker_pihole1'
dstpath='/opt/docker/docker_pihole2'
# user on sync server
syncusr='root'
@ -19,7 +20,7 @@ echo "pihole dns sync run: ${curdate}"
for i in "${syncarray[@]}"
do
echo "syncing $i"
scp ${syncusr}@${syncsvr}:${filepath}/${srcsvr}/${i} ${filepath}/${dstsvr}/${i}
scp ${syncusr}@${syncsvr}:${srcpath}/${i} ${dstpath}/${i}
done
echo "pihole dns sync run completed"