Bug 1129611

Summary: Docker daemon does not use options from /etc/sysconfig/docker
Product: [Fedora] Fedora EPEL Reporter: Hans-Joachim Skwirblies <hajo.skwirblies>
Component: docker-ioAssignee: Lokesh Mandvekar <lsm5>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: epel7CC: admiller, golang-updates, hushan.jia, jperrin, lsm5, mattdm, mgoldman, s, vbatts
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-08-13 11:01:03 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
Attachments:
Description Flags
Fixed unit file for systemd. none

Description Hans-Joachim Skwirblies 2014-08-13 10:54:50 UTC
Created attachment 926369 [details]
Fixed unit file for systemd.

Description of problem:

Docker does not use Parameters from /etc/sysconfig/docker

Expected behavior is that the daemon options in $DOCKER_OPTS (defined in /etc/sysconfig/docker) are used in the daemons exec.

Solution: systemd unit file (docker.service) should use $DOCKER_OPTS in ExecStart.

Version-Release number of selected component (if applicable):
docker-io-1.0.0-1.el7.x86_64, CentOS Linux release 7.0.1406 (Core)

How reproducible:
1. Graph-Directory (data-root for docker) is created in the wrong place
2. Daemon in ps without given options from DOCKER_OPTS

Steps to Reproduce:
1. Become root.
2. yum -y install docker-io
3. systemctl stop docker.service
4. echo "DOCKER_OPTS='-g=/docker-root'" > /etc/sysconfig/docker
5. systemctl start docker.service
6. test -d /docker-root || echo "fail"
7. ps -ef | grep -v grep | grep '\-g=/docker-root' || echo "fail"

Actual results:
1. Graph-Directory (data-root for docker) is created in the wrong place
2. Daemon in ps without given options from DOCKER_OPTS

Expected results:
1. /docker-root should be created
2. the docker daemon should be running with -g=/docker-root

Additional info:

Comment 1 Hans-Joachim Skwirblies 2014-08-13 11:01:03 UTC
duplicate of https://bugzilla.redhat.com/show_bug.cgi?id=1096849