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

Reintroduce missed docker secret handling #1748

Merged
merged 1 commit into from
Feb 23, 2025
Merged

Conversation

PromoFaux
Copy link
Member

What does this PR aim to accomplish?:

The V6 image was rebuilt from scratch - and this feature was accidentally missed.

Reproduces functionality of #584


By submitting this pull request, I confirm the following:

  1. I have read and understood the contributors guide, as well as this entire template. I understand which branch to base my commits and Pull Requests against.
  2. I have commented my proposed changes within the code and I have tested my changes.
  3. I am willing to help maintain this change if there are issues with it later.
  4. It is compatible with the EUPL 1.2 license
  5. I have squashed any insignificant commits. (git rebase)

  • I have read the above and my PR is ready for review. Check this box to confirm

Works exactly as it did in v5

Signed-off-by: Adam Warner <[email protected]>
@PromoFaux PromoFaux merged commit 278a78c into development Feb 23, 2025
3 of 4 checks passed
@PromoFaux PromoFaux deleted the password_file branch February 23, 2025 18:51
@yubiuser
Copy link
Member

yubiuser commented Feb 23, 2025

Why did you merge this so quickly? And ignored the failing test?
The 'docker' way to do such things would be to use an env file...

https://docs.docker.com/compose/how-tos/environment-variables/set-environment-variables/#use-the-env_file-attribute

@buckaroogeek
Copy link

Many thanks for the quick turn around!

@PromoFaux
Copy link
Member Author

... Not sure how I managed to merge it. Put the PR up just as I was going to dinner.... WIll fix the tests, however.

The 'docker' way

What makes you say this?

https://docs.docker.com/engine/swarm/secrets/#:~:text=Secrets%20are%20encrypted%20during%20transit,those%20service%20tasks%20are%20running.

@PromoFaux PromoFaux restored the password_file branch February 23, 2025 20:58
@rdwebdesign
Copy link
Member

The linked page says:

Note

Docker secrets are only available to swarm services, not to standalone containers ...

Does it work for stand alone docker installs too?


I thought we should recommend using --env_file attribute:

@PromoFaux
Copy link
Member Author

Does it work for stand alone docker installs too?

Certainly appears to work - at least it did when I tried it

Besides which, from the top of your second link: :)

Don't use environment variables to pass sensitive information, such as passwords, in to your containers. Use secrets instead.

@buckaroogeek
Copy link

I have been running a Pi-Hole (V5) container using Docker Secrets for quite some time. Works well. The Docker host is a Synology NAS.

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.

4 participants