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

Docker Detection Easily Broken #16

Open
sargun opened this issue Feb 15, 2019 · 1 comment · May be fixed by #19
Open

Docker Detection Easily Broken #16

sargun opened this issue Feb 15, 2019 · 1 comment · May be fixed by #19

Comments

@sargun
Copy link

sargun commented Feb 15, 2019

It appears like Docker detection happens by inspecting /proc/1/cgroup. If the cgroup paths themselves don't include "docker", then the detection fails. This happens if the user decides to control / configure the cgroup path.

I think there may be a couple other heuristics that we can use. Some other options:

  • look for /.dockerenv
  • look for /.dockerinit
@Silvanoc
Copy link

Silvanoc commented Aug 31, 2021

Please read GoogleContainerTools/kaniko#1686 (comment). The proposed and implemented heuristic has its issues... Just a heads-up.

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 a pull request may close this issue.

2 participants