-
Notifications
You must be signed in to change notification settings - Fork 18.6k
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
remove dockerinit #18355
Comments
ping @LK4D4 just to make sure that was the only thing hanging for removal |
gettting this for #17989 will help us not need libseccomp.a when compiling the binaries because dockerinit is static, it is trying to find it now |
I am all for this, the only problem I have is a side effect. Currently one of my patches uses the location of dockerinit to figure out where alternate docker binaries are stored. /usr/libexec/docker on Red Hat based OS. /usr/lib/docker on others. If we had a standard directory for helper executables to be installed... |
woohooooo we want the same thing <3 On Wed, Dec 2, 2015 at 7:05 AM, Daniel J Walsh notifications@github.com
|
@jfrazelle Yeah, I don't see other places. I never build dockerinit and |
I would like to take on this issue, but please correct me if I am misinterpreting it The following file needs to be removed: and the following file needs to be updated to not reference .dockerinit: |
it touches a lot of places a lot of things will need to be changed in On Thu, Dec 3, 2015 at 3:11 PM, Zuhayr Elahi notifications@github.com
|
Is anyone working on this issue currently? If no, I would like to work on it. |
@zelahi are you working on this? |
@sammyshj go ahead and take this one =) |
The dockerinit file is mentioned in many files. Should all these references be handled and then the dockerinit file be removed? |
@sammyshj yeah, I think so |
The |
@sammyshj InitPath shouldn't be needed after removing. |
Ya the files I specified weren't obviously the only ones like I've said On Friday, December 11, 2015, Alexander Morozov notifications@github.com
|
The original file path was merely the only one not in docker/docker so you On Friday, December 11, 2015, Jessie Frazelle jess@docker.com wrote:
|
Thanks for making things clear @LK4D4 and @jfrazelle . Working on it right now! |
Maybe this issue should be closed? :) |
@gianarb I think only in libnetwork. There is a long road ahead. |
@jfrazelle Hi. I I have some code that used to rely on the presence of /.dockerinit to detect whether it is run in a docker container (If not, log.Fatal with a warning so the users know they're not supposed to run that out of docker). What is the correct/suggested way to perform that sort of detection nowadays please? |
@mpl there is |
@tianon so when you've code which previously checked for presence of |
@mika there is |
@LK4D4 which tianon recommended to not rely on: " I would not recommend |
…check accordingly File /.dockerinit no longer exists. With Docker versions 1.11 and 1.12 there's /.dockerenv available, though it's not yet sure whether this will be present in the future too, so check for either /.dockerenv or a proper cgroup setup inside the docker container. File /proc/1/cgroup with Docker version 1.12.1 on Debian/jessie looks like: | root@4c3a1c6d773c:/# cat /proc/1/cgroup | 8:freezer:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 7:perf_event:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 6:net_cls,net_prio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 5:cpuset:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 4:blkio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 3:cpu,cpuacct:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 2:devices:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 1:name=systemd:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 See moby/moby#18355 and moby/moby#19490 for details. Change-Id: I2d649f65c8bba50193171ec7fbfd20160ddfc319
…check accordingly File /.dockerinit no longer exists. With Docker versions 1.11 and 1.12 there's /.dockerenv available, though it's not yet sure whether this will be present in the future too, so check for either /.dockerenv or a proper cgroup setup inside the docker container. File /proc/1/cgroup with Docker version 1.12.1 on Debian/jessie looks like: | root@4c3a1c6d773c:/# cat /proc/1/cgroup | 8:freezer:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 7:perf_event:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 6:net_cls,net_prio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 5:cpuset:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 4:blkio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 3:cpu,cpuacct:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 2:devices:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 1:name=systemd:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 See moby/moby#18355 and moby/moby#19490 for details. Change-Id: I79fff0eead1a11f80b461791b2285a65d706262a
…check accordingly File /.dockerinit no longer exists. With Docker versions 1.11 and 1.12 there's /.dockerenv available, though it's not yet sure whether this will be present in the future too, so check for either /.dockerenv or a proper cgroup setup inside the docker container. File /proc/1/cgroup with Docker version 1.12.1 on Debian/jessie looks like: | root@4c3a1c6d773c:/# cat /proc/1/cgroup | 8:freezer:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 7:perf_event:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 6:net_cls,net_prio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 5:cpuset:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 4:blkio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 3:cpu,cpuacct:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 2:devices:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 1:name=systemd:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 See moby/moby#18355 and moby/moby#19490 for details. Change-Id: I79fff0eead1a11f80b461791b2285a65d706262a (cherry picked from commit 6d35b85)
…check accordingly File /.dockerinit no longer exists. With Docker versions 1.11 and 1.12 there's /.dockerenv available, though it's not yet sure whether this will be present in the future too, so check for either /.dockerenv or a proper cgroup setup inside the docker container. File /proc/1/cgroup with Docker version 1.12.1 on Debian/jessie looks like: | root@4c3a1c6d773c:/# cat /proc/1/cgroup | 8:freezer:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 7:perf_event:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 6:net_cls,net_prio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 5:cpuset:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 4:blkio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 3:cpu,cpuacct:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 2:devices:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 1:name=systemd:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 See moby/moby#18355 and moby/moby#19490 for details. Change-Id: I79fff0eead1a11f80b461791b2285a65d706262a (cherry picked from commit 6d35b85)
docker removed /.dockerinit file and /.dockerenv is kind of deprecated. This change therefore checks for /.dockerenv and the cgroup See: moby/moby#18355 moby/moby#19490
docker removed /.dockerinit file and /.dockerenv is kind of deprecated. This change therefore checks for /.dockerenv and the cgroup See: moby/moby#18355 moby/moby#19490
…check accordingly The fix is comming from Mantis ticket 22099. File /.dockerinit no longer exists. With Docker versions 1.11 and 1.12 there's /.dockerenv available, though it's not yet sure whether this will be present in the future too, so check for either /.dockerenv or a proper cgroup setup inside the docker container. File /proc/1/cgroup with Docker version 1.12.1 on Debian/jessie looks like: | root@4c3a1c6d773c:/# cat /proc/1/cgroup | 8:freezer:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 7:perf_event:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 6:net_cls,net_prio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 5:cpuset:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 4:blkio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 3:cpu,cpuacct:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 2:devices:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 1:name=systemd:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 See moby/moby#18355 and moby/moby#19490 for details. Change-Id: I79fff0eead1a11f80b461791b2285a65d706262a (cherry picked from commit 6d35b85) (cherry picked from commit 8a9bb07)
…check accordingly The fix is comming from Mantis ticket 22099. File /.dockerinit no longer exists. With Docker versions 1.11 and 1.12 there's /.dockerenv available, though it's not yet sure whether this will be present in the future too, so check for either /.dockerenv or a proper cgroup setup inside the docker container. File /proc/1/cgroup with Docker version 1.12.1 on Debian/jessie looks like: | root@4c3a1c6d773c:/# cat /proc/1/cgroup | 8:freezer:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 7:perf_event:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 6:net_cls,net_prio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 5:cpuset:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 4:blkio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 3:cpu,cpuacct:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 2:devices:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 1:name=systemd:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 See moby/moby#18355 and moby/moby#19490 for details. Change-Id: I79fff0eead1a11f80b461791b2285a65d706262a (cherry picked from commit 6d35b85) (cherry picked from commit 8a9bb07)
…check accordingly The fix is comming from Mantis ticket 22099. File /.dockerinit no longer exists. With Docker versions 1.11 and 1.12 there's /.dockerenv available, though it's not yet sure whether this will be present in the future too, so check for either /.dockerenv or a proper cgroup setup inside the docker container. File /proc/1/cgroup with Docker version 1.12.1 on Debian/jessie looks like: | root@4c3a1c6d773c:/# cat /proc/1/cgroup | 8:freezer:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 7:perf_event:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 6:net_cls,net_prio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 5:cpuset:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 4:blkio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 3:cpu,cpuacct:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 2:devices:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 1:name=systemd:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 See moby/moby#18355 and moby/moby#19490 for details. Change-Id: I79fff0eead1a11f80b461791b2285a65d706262a (cherry picked from commit 6d35b85)
…check accordingly The fix is comming from Mantis ticket 22099. File /.dockerinit no longer exists. With Docker versions 1.11 and 1.12 there's /.dockerenv available, though it's not yet sure whether this will be present in the future too, so check for either /.dockerenv or a proper cgroup setup inside the docker container. File /proc/1/cgroup with Docker version 1.12.1 on Debian/jessie looks like: | root@4c3a1c6d773c:/# cat /proc/1/cgroup | 8:freezer:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 7:perf_event:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 6:net_cls,net_prio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 5:cpuset:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 4:blkio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 3:cpu,cpuacct:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 2:devices:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 1:name=systemd:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 See moby/moby#18355 and moby/moby#19490 for details. Change-Id: I79fff0eead1a11f80b461791b2285a65d706262a (cherry picked from commit 6d35b85) (cherry picked from commit 8a9bb07)
…check accordingly The fix is comming from Mantis ticket 22099. File /.dockerinit no longer exists. With Docker versions 1.11 and 1.12 there's /.dockerenv available, though it's not yet sure whether this will be present in the future too, so check for either /.dockerenv or a proper cgroup setup inside the docker container. File /proc/1/cgroup with Docker version 1.12.1 on Debian/jessie looks like: | root@4c3a1c6d773c:/# cat /proc/1/cgroup | 8:freezer:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 7:perf_event:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 6:net_cls,net_prio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 5:cpuset:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 4:blkio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 3:cpu,cpuacct:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 2:devices:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 1:name=systemd:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 See moby/moby#18355 and moby/moby#19490 for details. Change-Id: I79fff0eead1a11f80b461791b2285a65d706262a (cherry picked from commit 6d35b85) (cherry picked from commit 8a9bb07)
…check accordingly The fix is comming from Mantis ticket 22099. File /.dockerinit no longer exists. With Docker versions 1.11 and 1.12 there's /.dockerenv available, though it's not yet sure whether this will be present in the future too, so check for either /.dockerenv or a proper cgroup setup inside the docker container. File /proc/1/cgroup with Docker version 1.12.1 on Debian/jessie looks like: | root@4c3a1c6d773c:/# cat /proc/1/cgroup | 8:freezer:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 7:perf_event:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 6:net_cls,net_prio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 5:cpuset:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 4:blkio:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 3:cpu,cpuacct:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 2:devices:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 | 1:name=systemd:/docker/4c3a1c6d773c1a5675f24ff58540ff1a290489e7325e1e66ec2c3392aa3a1145 See moby/moby#18355 and moby/moby#19490 for details. Change-Id: I79fff0eead1a11f80b461791b2285a65d706262a (cherry picked from commit 6d35b85) (cherry picked from commit 8a9bb07)
/.dockerinit may no longer exist. Ref moby/moby#18355
the only thing relying on it is https://github.com/docker/libnetwork/blob/9fb7ba8fa01f0ddce99713799e760223c842fb4b/drivers/bridge/setup_bridgenetfiltering.go#L159
cc @rhatdan I think you wanted this as well
cc @tianon
The text was updated successfully, but these errors were encountered: