Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Pihole, Docker, "The Way"
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo Chat
View previous topic :: View next topic  
Author Message
unheatedgarage
n00b
n00b


Joined: 19 Sep 2016
Posts: 60

PostPosted: Sat Sep 01, 2018 11:41 am    Post subject: Pihole, Docker, "The Way" Reply with quote

It all started over a year ago. I had installed pihole on an ancient 32 bit thin client computer. I don’t know what its specs were, but I suspect they were a lot lower than a first gen Raspberry Pi. I was very, very impressed—not only with the old hardware, but with the fact that the pihole software worked so well—it installed easily (onto an ubuntu server), was a cinch to maintain, was light and easy on overhead, and as long as the lists weren’t too aggressive, you almost couldn’t tell it was there on the network guarding. Always silently guarding.

We grew to love that thing, and almost as soon as we named it (we called it The Tick), it died only after only few months of honorable service. After grieving, we never got around to setting up another one. Ever since then, the old browser-based adblockers seemed...inadequate.

We can rebuild him. We have the technology.

Every once in a while, I’d do a search around here to see if anyone else was much interested in installing pihole on Gentoo, but it didn’t seem there was much. Of course there’s this thread https://discourse.pi-hole.net/t/add-gentoo-as-a-supported-os/2011/10 but that never went anywhere. Anyway, me being the arrogant purist, I thought “who would want to run their crummy install scripts on our superior systems? That’s not the Gentoo Way. Besides, since I’m running systemd, surely it couldn’t be that hard to put together the nuts-and-bolts on one of the old helpers in my build cluster. This is The Way!”

I was going to get it figured out and set up my own overlay to share with the world! My name would be celebrated far and wide! Bare-breasted women would throw themselves at me! I would be the Bacchus of men!

After spending weeks (yes weeks) pouring over https://jacobsalmela.com/2015/06/16/block-millions-ads-network-wide-with-a-raspberry-pi-hole-2-0/ learning how to put those nuts-and-bolts together, and then going over to their github and getting into their code to learn a lot more about how they’re doing things, I learned a few things:

1. I have no idea what I’m doing.

2. They are really good at annotating their code if someone like me can follow along.

3. It all seems very elegant what they’re doing.

4. I have no idea what I’m doing.

Well, I got close—very, very close, to getting it to work, but by the time I got there, I realized I had spent a lot of my time trying to get their so called “crummy” gravity.sh scripts to work on my so called “pure” system, and then the absurdity of it all rolled over me like a 10 lbs. round of Double Gloucester cheese. This was not The Way.

So I turned back to running pihole on a virtual machine. After getting vbox set up, as I was just about to install it on that magical mystery computer, I saw the link to https://hub.docker.com/r/pihole/pihole/

Docker? Huh. I’ve heard the name thrown about for a few years, but never looked into it much, but I clicked on the link and found myself intrigued. After reading about it a bit, I took the dive to install it on my main desktop. Maybe this is The Way?

It took me a couple of hours to get the kernel settings right—having to rebuild twice because I missed a few—all the while I was thinking “nah, this will never work”. Then it took me another couple of hours of parsing the enthusiastic, but clearly intended for "people who already know what they’re doing" instructions on the pihole/pihole site, and then it came time for the moment of truth; it came time to hit enter on this command:

Code:
docker run -e ServerIP=192.168.1.112 -e TZ=America/Chicago -e WEBPASSWORD=******** -p 80:80 -p 53:53/tcp -p 53:53/udp -v /dir/for/pihole:/etc/pihole -v /dir/for/dnsmasq.d:/etc/dnsmasq.d pihole/pihole


Would you believe it? It worked!

It. Just. Worked!

After all that; after all those hours spent hunched over the keyboard, after all that time seeking The Way, all it took was just branching out and looking at a new technology. And after reading more about it, I’m getting more and more enthusiastic about Docker. What a great flow-like-water answer: not too heavy like a virtual computer; not too light either—seems like a Goldilocks solution. https://www.youtube.com/watch?v=Q5POuMHxW-0

So what do you good people think of it? Does it smack of Flatpak? Is it just another version of Snap? Is it antithetical to The Way? Where do you think Gentoo stands in an ever growing world of containerism, as it looks to hold high one of the few torches left burning the traditional message of modularity, individualism, and source-based distribution?

But then, maybe running Pihole in a Docker container on a Gentoo system IS The Way...

The Tick is dead, and I can let that rest, but Gentoo?

Gentoo is King. Long live the King.
_________________
I'm not even mad; I'm impressed!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo Chat All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum