1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00
Commit graph

19 commits

Author SHA1 Message Date
Cyprian Gracz
74cf6157ef Stop returns 0 when docker service was not running
In case when docker was not running init script stop was returning value <> 0.
Due to this fact it was impossible to uninstall the docker-engine if the docker service was stopped.

Signed-off-by: Cyprian Gracz <cyprian.gracz@micro-jumbo.eu>

Fixed message logging

Signed-off-by: Cyprian Gracz <cyprian.gracz@micro-jumbo.eu>
2016-11-28 12:27:21 +01:00
Liam Macgillavry
11eda60848 missed DOCKER->DOCKERD change in 1ac1b78b3a for 'status'
Signed-off-by: Liam Macgillavry <liam@kumina.nl>
2016-08-19 11:08:52 +02:00
Sebastiaan van Stijn
428d7337e8
Don't set ulimits (nproc)
There is a not-insignificant performance overhead for all containers (if
containerd is a child of Docker, which is the current setup) if rlimits are
set on the main Docker daemon process (because the limits
propogate to all children).

We recommend using cgroups to do container-local accounting.

This applies the change added in 8db61095a3
to other init scripts.

Note that nfile cannot be set to unlimited, and the limit
is hardcoded to 1048576 (2^20) , see:
http://stackoverflow.com/a/1213069/1811501

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2016-07-13 17:15:19 +02:00
Sebastiaan van Stijn
fa077f7496
use tabs for indentation
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2016-07-12 23:16:55 +02:00
Antonio Murdaca
1ac1b78b3a contrib: init: use dockerd
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
2016-05-11 11:00:11 +02:00
Ewa Czechowska
5c94a9e800 #16560 Add timeout to sudo service docker stop on sysvinit
Add 10 seconds timeout when running `sudo service docker stop`. This is
especially needed when running `sudo service docker restart`. Otherwise,
`restart` results in exitstatus 1, because `start` has nothing to do.

Signed-off-by: Ewa Czechowska <ewa@ai-traders.com>
2015-09-24 19:41:32 +00:00
Matthias Rampke
01c5cfcc56 Do not try to guess "docker" in Debian SysV init script
On boot, the init script is invoked from `/etc/rcN.d/S20docker` (where N
is the runlevel). Consequently, the init script tried to find the
defaults at `/etc/defaults/S20docker` and the binary at
`/usr/bin/S20docker`. This causes the docker daemon to fail at boot with
the error

    /usr/bin/S20docker not present or not executable

Starting it manually works because it invokes `/etc/init.d/docker` which
has the correct basename.

Fix this by hardcoding "docker" as the base name.

Signed-off-by: Matthias Rampke <mr@soundcloud.com>
2015-09-23 11:27:34 +00:00
David Calavera
346ce4f8d2 Update init scripts to use docker daemon.
Signed-off-by: David Calavera <david.calavera@gmail.com>
2015-07-22 11:24:38 -07:00
David Calavera
d8592eaff8 Revert "contrib/init: unshare mount namespace for inits"
This reverts commit b6569b6b82.

Signed-off-by: David Calavera <david.calavera@gmail.com>
2015-06-15 10:35:17 -07:00
Steven Richards
e5ff643aed Fixes #13031 - Check for upstart or init is not detecting properly
This will now properly check whether /etc/init.d/docker or service docker is
invoking the script and respond to the user accordingly.

Signed-off-by: Steven Richards <steven@axiomzen.co>
2015-05-28 09:52:05 -07:00
Vincent Batts
b6569b6b82 contrib/init: unshare mount namespace for inits
* openrc
* sysvinit-debian
* upstart

Signed-off-by: Vincent Batts <vbatts@redhat.com>
2015-04-23 14:08:37 -04:00
Tianon Gravi
478fdaf933 Fix several minor issues with Debian sysvinit script
- add `set -e` to make failing commands bail the script
- remove trailing `exit 0` which is just extraneous anyhow
- adjust `status_of_proc` options to pass in `$DOCKER_DESC` so we get consistently styled messages like `Docker is running` or `Docker is not running` or `could not access PID file for Docker`

Signed-off-by: Andrew Page <admwiggin@gmail.com>
2014-08-07 16:45:22 -06:00
Tianon Gravi
4f0fbb885e Add a conditional to contrib/init/sysvinit-debian/docker for Dash vs Bash support
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2014-07-14 12:34:04 -06:00
Tianon Gravi
bae79c3e72 Add NOFILE and NPROC ulimit settings to the SysV init script
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2014-07-02 09:38:19 -06:00
Joe Beda
c11fadb282 Make debian init work when called quickly.
We use the start-stop-daemon pid creation mechanism in addition the intrinsic built into docker.  This means the pid file is guaranteed to be written out by the time the script exits.

See #6184.

Docker-DCO-1.1-Signed-off-by: Joe Beda <joe.github@bedafamily.com> (github: jbeda)
2014-06-03 16:57:32 -07:00
Tianon Gravi
36d913078b Add "Should-Start" cgroupfs-mount and cgroup-lite to sysvinit-debian init script
It's fine to list both here because "Should-Start" is a loose binding (ie, if the listed service exists, it'll be started first, but otherwise, this one will start without it).

Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2014-05-07 09:46:41 -06:00
Tianon Gravi
76dc670f41 Add variable for DOCKER_LOGFILE to sysvinit and use append instead of overwrite in opening the logfile
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2014-03-11 01:40:31 -06:00
Tianon Gravi
b21f8872cc Fix init script cgroup mounting workarounds to be more similar to cgroupfs-mount and thus work properly
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2014-03-11 01:39:06 -06:00
Tianon Gravi
50082f792b Fix a few packaging bugs, including and especially a temporary patch to our upstart script to mount cgroups properly
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2014-03-10 03:27:46 -06:00
Renamed from contrib/init/sysvinit/docker (Browse further)