I Broke Pi-Hole
As a way to gain more experience with cybersecurity software, I installed Pi-hole in my desktop computer. Pi-hole is a Linux network-level advertisement and Internet tracker blocking application.
But static IPs are required by Pi-hole, which to me becomes a security compromise. So, in order to continue using dynamic addresses, I wrote a Bash script which gets current addresses and then replaces a Pi-hole configuration file. Below are the Bash instructions I used to return current IPv4 and IPv6 network addresses:
ADDRIPV4=$(echo $(ip a | grep 'inet 10') | cut -d' ' -f 2 | cut -d'/' -f 1); echo $ADDRIPV4
ADDRIPV6=$(echo $(ip a | grep '/64 scope global dynamic noprefixroute') | cut -d' ' -f 2 | cut -d'/' -f 1); echo $ADDRIPV6
But, for some reason, by replacing that configuration file I referred to, I broke that Pi-hole installation, so, for now, I decided not to use the software. That being said, I still like the software, and would recommend that others should try it out themselves.
In the future, I may purchase a Raspberry Pi, since Pi-hole was originally designed to be installed in a RPi.