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

Add logs to print environment variable details when creating a container #129292

Open
yangyefei90 opened this issue Dec 19, 2024 · 4 comments
Open
Labels
kind/feature Categorizes issue or PR as related to a new feature. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. sig/node Categorizes an issue or PR as relevant to SIG Node.

Comments

@yangyefei90
Copy link

What would you like to be added?

Add logs to print environment variable details when creating a container

Why is this needed?

Pod supports obtaining the Pod IP from the status and injecting it into the pod as an environment variable. In actual production environments, we occasionally encounter situations where the Pod IP environment variable fails to inject. When the business side asks us to identify the cause, we cannot effectively demonstrate whether the environment variable was injected into the pod as expected. Therefore, it is necessary to print out the specific content of the environment variables when creating the container to facilitate problem identification and troubleshooting.

@yangyefei90 yangyefei90 added the kind/feature Categorizes issue or PR as related to a new feature. label Dec 19, 2024
@k8s-ci-robot k8s-ci-robot added the needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. label Dec 19, 2024
@k8s-ci-robot
Copy link
Contributor

This issue is currently awaiting triage.

If a SIG or subproject determines this is a relevant issue, they will accept it by applying the triage/accepted label and provide further guidance.

The triage/accepted label can be added by org members by writing /triage accepted in a comment.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot added the needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. label Dec 19, 2024
@vaibhav2107
Copy link
Member

/sig node

@k8s-ci-robot k8s-ci-robot added sig/node Categorizes an issue or PR as relevant to SIG Node. and removed needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. labels Dec 19, 2024
@kannon92
Copy link
Contributor

I think this could be a serious security issue. I don't think k8s should print environment variables as that could leak important information into the kubelet logs.

@kannon92
Copy link
Contributor

Seems that @dims agrees.

#129293 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature Categorizes issue or PR as related to a new feature. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. sig/node Categorizes an issue or PR as relevant to SIG Node.
Projects
None yet
Development

No branches or pull requests

4 participants