podman sets (& overrides) the HOSTNAME env variable #8886
Labels
In Progress
This issue is actively being worked by the assignee, please do not work on this at this time.
kind/bug
Categorizes issue or PR as related to a bug.
locked - please file new issue/PR
Assist humans wanting to comment on an old issue or PR with locked comments.
Is this a BUG REPORT or FEATURE REQUEST? (leave only one on its own line)
/kind bug
Description
I'm trying to run an image that made the (questionable) choice to bind the network server to the environment's HOSTNAME. Therefore, I'd like to pass HOSTNAME=0.0.0.0 in the container's environment.
However, it seems that podman sets the HOSTNAME environment variable unconditionally to the container (or pod's) hostname. What's worse is that it's being set, even if one passes
-e HOSTNAME=something-else
.Steps to reproduce the issue:
podman run -h foo -e HOSTNAME=bar --rm busybox /bin/sh -c 'echo $HOSTNAME'
podman run -e HOSTNAME=bar --rm busybox /bin/sh -c 'echo $HOSTNAME'
Describe the results you received:
foo
ad76a346f1fa
Describe the results you expected:
bar
bar
Additional information you deem important (e.g. issue happens only occasionally):
Output of
podman version
:Output of
podman info --debug
:Package info (e.g. output of
rpm -q podman
orapt list podman
):Have you tested with the latest version of Podman and have you checked the Podman Troubleshooting Guide?
Yes
Additional environment details (AWS, VirtualBox, physical, etc.):
Physical.
The text was updated successfully, but these errors were encountered: