@deemon
Put the domain facebook.com
in a file called blocklist (you can add more domains by adding a domain per line)
Then, in a shell script:
#!/usr/bin/env bash
blockDomains=$(<blocklist)
for domain in ${blockDomains[@]}; do
/usr/local/bin/pihole --wild $domain
done
If you want to remove a domain, just add -d
flag to the pihole command:
/usr/local/bin/pihole --wild -d $domain
The entry in the domains list will look like:
(\.|^)facebook\.com$
To deny all domains from a custom Regex:
pihole --regex "[a-z]test.com"
Pinned Comments
max.bra commented on 2025-02-21 21:44 (UTC)
ArchLinux Pi-hole is not officially supported by Pi-hole project. In case of bugs and malfunctions please DO NOT file a report upstream.
First of all check if the wiki (https://wiki.archlinux.org/index.php/Pi-hole) can help then ask here for assistance and tips.
When it will be excluded that the problem does not depend on ArchLinux we will file a bug upstream.
max.bra commented on 2025-02-21 17:56 (UTC)
to update to pi-hole 6, please use pi-hole-core pi-hole-ftl and pi-hole-web packages.