Commit Graph

33 Commits

Author SHA1 Message Date
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
Tianon Gravi 7abe70c0b1 Add NOFILE and NPROC ulimit settings to the OpenRC init script
Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2014-07-02 09:36:57 -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
Jeffrey Bolle c52889db27 Ensure networking is up before starting docker
This resolves a problem that I have been having where docker starts before networking is up. See issue #5944 for more details.

Docker-DCO-1.1-Signed-off-by: Jeffrey Bolle <jeffreybolle@gmail.com> (github: jeffreybolle)
2014-05-24 19:03:11 +01:00
Tianon Gravi 47aa9f5a0e Merge pull request #5844 from stpierre/init-script-wait-for-pidfile
Wait for pidfile to exist when starting with RedHat init script
2014-05-20 10:25:03 -06:00
unclejack ba0c829291 contrib/init/upstart: start on local-filesystems
This changes the upstart init script to start on `local-filesystems`.

Docker-DCO-1.1-Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com> (github: unclejack)
2014-05-16 19:12:59 +03:00
Chris St. Pierre 1ee423bd5d added timeout when waiting for docker pidfile
Docker-DCO-1.1-Signed-off-by: Chris St. Pierre <chris.a.st.pierre@gmail.com> (github: stpierre)
2014-05-16 09:36:54 -04:00
Chris St. Pierre a598dba134 Wait for pidfile to exist when starting with Redhat init script
Fixes #5359

Docker-DCO-1.1-Signed-off-by: Chris St. Pierre <chris.a.st.pierre@gmail.com> (github: stpierre)
2014-05-16 09:08:59 -04: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
Michael Gorsuch 73ee4879af upstart: use exec here so upstart can monitor the process and not just a shell
Docker-DCO-1.1-Signed-off-by: Michael Gorsuch <michael.gorsuch@gmail.com> (github: gorsuch)
2014-03-27 12:44:33 -05:00
Brian Goff e27c635c06 Add upstart nofile/noproc similar to systemd init
Docker-DCO-1.1-Signed-off-by: Brian Goff <cpuguy83@gmail.com> (github: cpuguy83)
2014-03-18 16:27:20 -04:00
Tianon Gravi 44fe8cbbd1 Update to double-dash everywhere
These were found using `git grep -nE '[^-a-zA-Z0-9<>]-[a-zA-Z0-9]{2}'` (fair warning: _many_ false positives there).

Docker-DCO-1.1-Signed-off-by: Andrew Page <admwiggin@gmail.com> (github: tianon)
2014-03-13 11:46:02 -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
Lokesh Mandvekar 291d5e642e bump open files and procs limit via unitfile
Docker-DCO-1.1-Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com> (github: lsm5)

	modified:   contrib/init/systemd/docker.service
	modified:   contrib/init/systemd/socket-activation/docker.service
2014-03-04 22:29:51 -05:00
Adam Miller 4317011e21 remove unneeded sysctl changes in sysvinit-redhat init script
Docker-DCO-1.1-Signed-off-by: Adam Miller <admiller@redhat.com> (github: maxamillion)
2014-02-13 12:11:38 -06:00
Adam Miller 2222cba5ac Added sysvinit/sysconfig files for redhat family of distros (RHEL/CentOS/SL/etc.)
Docker-DCO-1.1-Signed-off-by: Adam Miller <admiller@redhat.com> (github: maxamillion)
2014-02-12 12:03:32 -06:00
Brandon Philips 4dab34c204 contrib: systemd: make socket-activation Restart=always
Do as was done to f09a78cd21 in the
socket-activation example.

Docker-DCO-1.1-Signed-off-by: Brandon Philips <brandon.philips@coreos.com> (github: philips)
2014-01-29 17:42:32 -08:00
Lokesh Mandvekar a9d0bbcfc6 remove ip fowarding from systemd (fixed: commit #3801)
Docker-DCO-1.1-Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com> (github: lsm5)
2014-01-29 11:06:23 -05:00
Lokesh Mandvekar f09a78cd21 ExecStartPre commands updated
Docker-DCO-1.1-Signed-off-by: Lokesh Mandvekar <lsm5@redhat.com> (github: lsm5)

systemd service no longer does '/bin/mount/ --make-rprivate /'.
Core issue fixed by Alex Larsson (commit 157d99a).

ip forwarding enabled.
2014-01-29 11:06:23 -05:00
Brandon Philips 1f44921c51 fix(contrib/init/systemd): remove mount rprivate
Docker does this now via 157d99a727

Docker-DCO-1.1-Signed-off-by: Brandon Philips <brandon.philips@coreos.com> (github: philips)
2014-01-27 17:18:09 -08:00
Brandon Philips 7f9d3268bf Allow fd:// like unix:// and tcp://
Somthing like 20605eb310

Docker-DCO-1.1-Signed-off-by: Brandon Philips <brandon.philips@coreos.com> (github: philips)
2014-01-27 17:18:09 -08:00
Brandon Philips 87fb2c973d server: add socket activation
This adds the ability to socket activate docker by passing in
`-H fd://*` along with examples systemd configuration files.

The fastest way to test this is to run:

```
/usr/lib/systemd/systemd-activate -l 127.0.0.1:2001 /usr/bin/docker -d -H 'fd://*'
docker -H tcp://127.0.0.1:2001 ps
```

Docker-DCO-1.1-Signed-off-by: Brandon Philips <brandon.philips@coreos.com> (github: philips)
2014-01-27 17:17:07 -08:00
Tianon Gravi 75e9cff98c Update systemd service file with suggestions from @seblu 2013-11-27 16:55:37 -07:00
Tianon Gravi b94e9ed0de Merge pull request #2652 from tianon/upstart-defaults-too
Add /etc/default/docker support to upstart, too (mirroring sysvinit)
2013-11-13 10:42:41 -08:00
Tianon Gravi 88edba7e86 Update upstart check in sysvinit to be exactly the same as the init_is_upstart function from /lib/lsb/init-functions (which isn't available in 12.04 or we'd use it directly) 2013-11-11 11:57:25 -07:00
Tianon Gravi 7cf7dda87d Add /etc/default/docker support to upstart, too (mirroring sysvinit) 2013-11-11 11:13:16 -07:00
Tianon Gravi bb76157d24 Fix sysvinit upstart detection and give it a pretty message 2013-11-11 11:10:19 -07:00
Tianon Gravi 8ad46ef401 Merge pull request #2365 from tianon/sysvinit-consistency
Update sysvinit script to fix a few inconsistencies and be more useful/correct downstream
2013-11-04 15:34:51 -08:00
Brandon Philips 393562340c fix(systemd): provide a better description
Fix-up the docker service file description to declare what the service is not what it does.

When a systemd machine starts up the Description of each unit scrolls by instead of the service's filename. Because the current description doesn't say what it is it isn't very friendly:

```
Oct 31 20:40:49 localhost systemd[1]: Started Update Engine.
Oct 31 20:40:49 localhost systemd[1]: Starting Multi-User System.
Oct 31 20:40:49 localhost systemd[1]: Reached target Multi-User System.
Oct 31 20:40:49 localhost systemd[1]: Starting Easily create lightweight, portable, self-sufficient containers from any application!...
Oct 31 20:40:49 localhost systemd[1]: Started Easily create lightweight, portable, self-sufficient containers from any application!.
```
2013-10-31 14:41:49 -07:00
Tianon Gravi 865649d7ac Update sysvinit script to fix a few inconsistencies and be more useful/correct downstream 2013-10-28 14:08:21 -06:00
Tianon Gravi c405d53b6e Add initial init scripts library, including systemd, sysvinit, upstart, and openrc 2013-10-17 12:03:49 -06:00