Skip to content

Conversation

@rugk
Copy link
Contributor

@rugk rugk commented Nov 3, 2023

  • You can start it as usual, .env file is automatically used.
  • IMHO easier and cleaner to configure.
  • Also removed the <host> as it makes this not-runnable out-of-the-box. I need this for Create OWASP security scan of Docker container #69 and this was the initial idea of making this PR.
  • The ${:?} syntax is a bash-like thing to produce a proper error message if the variable is not provided.

I checked the setup should basically start (just got a permission error as the UID/GID is wrong).

rugk added 2 commits November 3, 2023 17:23
* You can start it as usual, `.env` file is automatically used.
* IMHO easier and cleaner to configure.
* Also removed the `<host>` as it makes this not-runnable out-of-the-box. I need this for Ravinou#69 and this was the initial idea of making this PR.
* The `${:?}` syntax is a bash-like thing to produce a proper error message if the variable is not provided.

I checked the setup should basically start (just got a permission error as the UID/GID is wrong).
@Ravinou
Copy link
Owner

Ravinou commented Nov 5, 2023

Hi! I'm not in favor of using an .env file for docker-compose. If people want to do it, they are free to do it, but for the example it makes the installation more "complex" and it doesn't allow to show the indispendable variables anymore. It's less "out-of-the-box".

If we're going to integrate OWASP (which I think is a good idea), I'd like to adapt the OWASP config without affecting the readability of how to run borgwarehouse.

@rugk
Copy link
Contributor Author

rugk commented Nov 5, 2023

Hmm, IMHO it's easier though…

it makes the installation more "complex"

Well you have two files now, but you only need to touch one file anyway? I would not call that too complex…

doesn't allow to show the indispendable variables anymore

Hmm how do you mean that? IMHO it is easier to see and adjust all the variables you need as you can basically just cat .env respectively see them. You also have various ways to pass/use different ones and you can obviously even omit the .env file and pass all variables as system .env variables. So IMHO, this is more flexible (which I needed for my use case).

@Ravinou
Copy link
Owner

Ravinou commented Nov 5, 2023

@rugk ok you convinced me :)
Anyway, it's true that secrets should always be in an env file rather than a conf file, it's a better practice.

@rugk
Copy link
Contributor Author

rugk commented Nov 9, 2023

Okay great, then well… you'd need to approve and merge this, don't you? 🙃

BTW secret management is a huge topic and there are a lot of solutions for that too, but IMHO that would be a next topic and maybe even just be too much for this simple docker-compose.yml for now, so maybe env variables are better (as you can choose how and where to pass them) than before after all though.

@Ravinou
Copy link
Owner

Ravinou commented Nov 10, 2023

Okay great, then well… you'd need to approve and merge this, don't you? 🙃

Can you just please check my comments in review and modify your PR ? Thank you

@rugk
Copy link
Contributor Author

rugk commented Nov 10, 2023

I see no comments, is your review maybe still pending? You need to submit it to submit all the comments… 🙃

@Ravinou
Copy link
Owner

Ravinou commented Nov 11, 2023

I see no comments, is your review maybe still pending? You need to submit it to submit all the comments… 🙃

No comment ... it's done 😂😂😂

@rugk rugk requested a review from Ravinou December 5, 2023 20:03
@rugk
Copy link
Contributor Author

rugk commented Dec 28, 2023

@Ravinou any news? 👀

@Ravinou Ravinou changed the base branch from main to develop December 30, 2023 17:04
@Ravinou Ravinou merged commit 9470957 into Ravinou:develop Dec 30, 2023
@Ravinou
Copy link
Owner

Ravinou commented Dec 30, 2023

@rugk Sorry for the delay, difficult end of year for me.

Thanks it's merged on the develop branch. It will be part of the next release in the next few days.

@rugk rugk deleted the container/environmental-variables branch January 1, 2024 18:43
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