Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Shawn Webb
scripts
Commits
0e51469a
Commit
0e51469a
authored
Apr 09, 2021
by
Shawn Webb
Browse files
Add initial DNS cronjob script
parents
Changes
1
Hide whitespace changes
Inline
Side-by-side
dns/cron.sh
0 → 100644
View file @
0e51469a
#!/bin/sh -ex
if
[
"
$(
id
-u
)
"
-ne
"0"
]
;
then
echo
"[-] Must be run as root"
1>&2
exit
1
fi
myzones
=
"/usr/local/etc/void-zones/my_void_hosts.txt"
cd
/data/Ultimate.Hosts.Blacklist
git pull
grep
'^0\.0\.0\.0'
hosts/hosts0
>
${
myzones
}
grep
'^0\.0\.0\.0'
hosts/hosts1
>>
${
myzones
}
/usr/local/bin/void-zones-update.sh
service unbound restart
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment