EnvKey Source Installation Docker Containers #91
Unanswered
green2jello
asked this question in
Q&A
Replies: 1 comment
-
Thanks @green2jello, that makes sense and seems like a better approach. Could you put up those changes as a PR? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I was having trouble getting the IS_DOCKER var to set in the installation script using an ubuntu:22.04 container during build time.
It looks like with current ubuntu docker images that the result from listing out the cgroup does not include anything with docker:
If there is a desire to still use something in the
proc
vicinity to confirm that you are in a docker container still I think that (/.dockerenv
is a non permanent hack from the buildkit devs from what I remember) is using/proc/self/mountinfo
. My suggested changes for that if statement is:if [ $(cat /proc/1/cgroup 2> /dev/null | grep docker | wc -l) -gt 0 ] || [ -f /.dockerenv ] || [ $(cat /proc/self/mountinfo 2> /dev/null | grep docker | wc -l) -gt 0 ]; then
I confirmed this installation script worked still with ubuntu:22.04, python:3, rocklylinux:9, and alpine:latest. Otherwise the base installation script would route towards the else statement with the sudo call.
Beta Was this translation helpful? Give feedback.
All reactions