Red Hat Bugzilla – Bug 1102568
Wrong path of default secrets docker tries to open
Last modified: 2015-03-04 22:18:52 EST
Description of problem: With docker-0.11.1-6.el7.x86_64, the default secrets path is #ll /var/lib/docker/secrets/ total 0 but the docker will try to find it in /etc/docker/secrets Version-Release number of selected component (if applicable): docker-0.11.1-6.el7.x86_64 How reproducible: 100% Steps to Reproduce: 1.# docker run -t -d fedora /bin/bash 3a94dbcefd8d269af97376d37a103374c98c8418953c640e101e57d335ad3c4b 2014/05/29 16:33:08 Error: Cannot start container 3a94dbcefd8d269af97376d37a103374c98c8418953c640e101e57d335ad3c4b: open /etc/docker/secrets: no such file or directory 2. #mkdir -p /etc/docker/secrets #docker run -t -d fedora /bin/bash f409532a826485cb823607d60273fe2d452860f5469c80938e0813e3d8a67544 # docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES f409532a8264 fedora:20 /bin/bash 5 seconds ago Up 4 seconds elegant_ardinghelli0 3.RHEL version default location #ll /var/lib/docker/secrets total 0
https://github.com/lsm5/docker/commit/3253dbcc06be3b9cfc34b414d22e0e5ab39ebdf2 should fix it
(In reply to Lokesh Mandvekar from comment #2) > https://github.com/lsm5/docker/commit/ > 3253dbcc06be3b9cfc34b414d22e0e5ab39ebdf2 should fix it This is probably wrong. Will update asap.
Hello lsm5, The command doesn't stop start container and the new option --grant-secret works too, but it still locate at /etc/docker. So few questions.. 1.Is "/etc/docker" the final rhel version? 2.Doe the bug verifry with steps below or some new patches will go into the build? With docker-0.11.1-15.el7.x86_64, # docker secret list SECRET NAME FROM HOST etc-pki-entitlement * rhel7.repo * # ll /etc/docker/secrets/ total 0 lrwxrwxrwx. 1 root root 20 Jun 4 13:52 etc-pki-entitlement -> /etc/pki/entitlement lrwxrwxrwx. 1 root root 28 Jun 4 13:52 rhel7.repo -> /etc/yum.repos.d/redhat.repo # ll /var/lib/docker/secrets/ total 0 # docker run -t -d fedora /bin/bash d2c87206918f45c0d255a1c94d73002634b0933e5f2f6671f7b227b9a5cde5f8 #docker run -t -d --grant-secret=etc-pki-entitlement fedora /bin/bash decfac6b2af97bf86f24f5b34bd5ec06b08773f902959d7928652e2599c446e6
Hi, this should be fixed with docker-0.11.1-19.el7 available in RHEL7
(In reply to Lokesh Mandvekar from comment #5) > Hi, > > this should be fixed with docker-0.11.1-19.el7 available in RHEL7 Yes, make up the steps # rpm -q docker docker-0.11.1-19.el7.x86_64 # ll /etc/docker/ ls: cannot access /etc/docker/: No such file or directory # ll /usr/share/rhel/secrets/ total 0 lrwxrwxrwx. 1 root root 20 Jun 11 16:32 etc-pki-entitlement -> /etc/pki/entitlement lrwxrwxrwx. 1 root root 28 Jun 11 16:32 rhel7.repo -> /etc/yum.repos.d/redhat.repo # docker run -t -d redhat/rhel7beta /bin/bash ab4e81944d05bc12e13613b57df2674680f8934be660d862f83feec8f9eafbfd
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://rhn.redhat.com/errata/RHSA-2015-0623.html