Fix environment variable precedents
Allow environment variables set in the host os to override the value of a variable defined in a .env file. This is consistent with docker's environment variable precedence. Per https://docs.docker.com/compose/environment-variables/envvars-precedence/#advanced-example
I'd love to submit some tests but I can't even find existing tests that test the env/env-file features as is. Is there one I can use a template someplace?
@p12tic bump on this issue. I (and presumably @wgnathanael) would love to get this merged as I am currently relying on it in my own fork to be able to use podman-compose in production, but it needs tests. Happy to contribute some, but as @wgnathanael says, there doesn't seem to be any infrastructure in place for testing the existing environment variable code. Do you have any sense of how this could be tested in a reasonably straightforward way?
Thanks for the bump, I somehow missed @wgnathanael comment. If there is no testing infrastructure for a feature, it's more of a responsibility of the maintainer to define one instead of infrequent contributors. I will merge this PR as is.
Rebased and fixed merge conflict.