Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker Compatibility & Automatic Git Dir Variable #28

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Docker Compatibility & Automatic Git Dir Variable #28

wants to merge 2 commits into from

Conversation

Banner-Keith
Copy link

This is a continuation of #18 by @IarwainBen-adar

I noticed that there had been no response there for 25 days, and there were some merge conflicts.

I pulled this down and created a branch to work from. This is the sum of my changes added to the changes that @IarwaiBen-adar had made.

I have tested it with Pi-Hole v5 running in docker.
I have a docker container running in UnRAID as the master, and a container on a Raspberrry Pi as a downstream pi-hole. Push and Pull is working great.

I also made it so that you don't have to set the personal_git_dir repo as it will be set automatically based on the location of the pihole-cloudsync script. It works regardless of where you are when you execute the script.

With this change you also don't need to change the pihole_dir or dnsmasq_dir paths if you are running in a container. It will look for those paths inside of the container and find the mapped volume outside of the container.

I am very open to feedback if you see anything that you don't like or anything that makes it more difficult for those not running a container. I don't have that setup to test, but I don't see anything in my changes that would have a negative impact on non-docker users.

The way that @IarwainBen-adar had this set up was to auto-detect if there is a pihole docker container. If we wanted we could have that be a flag that is passed, but I think this solution is fine since it is very unlikely that someone would have an active pihole container and a local install since they can't both be on port 53.

README.md Show resolved Hide resolved
README.md Show resolved Hide resolved
Copy link
Owner

@stevejenkins stevejenkins left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks. This looks great. Sorry for the massive delay. I'm finally getting back into my nerdy projects. :)

@stevejenkins
Copy link
Owner

Well phooey. Looks like it has a conflict with the head branch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants