Closed larieu closed 2 years ago
you might have the solution here https://askubuntu.com/questions/491374/terminal-sudo-apt-get-command-not-found
Nope the system is centos 7 based ( a nethserver with the pihole form that distribution )
the workaround for gawk is this
rpm -q gawk | grep -qw gawk || dnf install gawk -y
instead of the apt-get dpkg ... ubuntu command
the second problem arise when gawk in centos 7 is not having the -i inpalce as otion
gawk -i inplace '!a[$0]++' $blackListFile wait gawk -i inplace '!a[$0]++' $blacklist
the third problem is that on centos 7 pihole ( even the last one ) does not accept -x commands for example the standard pihole -g results in
pihole -g The commands are : pihole ip : find the IP of pihole given by your dhcp server pihole status : retrieve the status of pihole container pihole env : retrieve all the environment vars of the container pihole bash : start a shell inside the container pihole restart: Restart the pihole container pihole start: Start the pihole container pihole stop: Stop the pihole container pihole destroy: Delete the pihole container pihole build: Delete then create the pihole container pihole upgrade: Upgrade docker image, delete then create the pihole container pihole ps: Container information pihole log: Display the error log of the container
as workaround I have installed a new centos 8 with pihole into a VM and there with the minor change of dgpk > rpm -q works well
It starts with this error
/opt/youTube_ads_4_pi-hole/youtube.sh: line 32: dpkg: command not found sudo: apt-get: command not found
then is going .... crazy