compose-go icon indicating copy to clipboard operation
compose-go copied to clipboard

keep empty environment variables as those must be UNSET in container

Open ndeloof opened this issue 1 year ago • 0 comments

environment FOO with no value nor equal sign means "propagate value from user's environment, or unset variable" So, as we resolve environment, empty value with no matching entry in user's environment MUST not result into removing entry from service definition. Build args do not follow this rule. --build-arg FOO will propagate user's environment value, but if not set build arg will keep using value set by Dockerfile

fixes https://github.com/docker/compose/issues/11962 supersede https://github.com/compose-spec/compose-go/pull/634 see https://github.com/docker/compose/pull/11965

ndeloof avatar Jul 04 '24 07:07 ndeloof