Skip to content
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

Don't use supervisor as the init process #24

Closed
parente opened this issue Sep 4, 2015 · 5 comments
Closed

Don't use supervisor as the init process #24

parente opened this issue Sep 4, 2015 · 5 comments

Comments

@parente
Copy link
Member

parente commented Sep 4, 2015

See jupyter/notebook#334 (comment) for background.

Possible fixes ...

  1. Switch to phusion/baseimage. Concern: size and change of OS.

    phusion/baseimage              latest              e9f50c1887ea        7 weeks ago         237.7 MB
    ubuntu                         14.04               d2a0ecffe6fa        8 weeks ago         188.4 MB
    debian                         wheezy              065218d54d7d        11 weeks ago        84.97 MB
    
  2. Use runit like phusion/baseimage does (http://www.sourcediver.org/blog/2014/11/17/using-runit-in-a-docker-container/). Concern: env var workaround described therein.

  3. Port phusion/baseimage to debian. Concern: yet another thing to maintain.

  4. Wait for docker to give reaping "for free" (Evented Process Monitor moby/moby#11529).

@krallin
Copy link

krallin commented Sep 10, 2015

Hey there,

I apologize for the shameless plug, but I noticed you were considering using phusion/baseimage for its zombie reaping capabilities but were concerned about the size and having to port it to Debian.

I happen to have written a tool just for that. It's called tini, and it's used in a handful of official Docker images (see here: https://github.com/docker-library/official-images#init) — although it's not officially endorsed. Thought you might want to have a look!

If you're curious; you can find it here on Github: https://github.com/krallin/tini

@mjbright
Copy link

I love the name already, 'tini' !

On 10 September 2015 at 19:45, Thomas Orozco notifications@github.com
wrote:

Hey there,

I apologize for the shameless plug, but I noticed you were considering
using phusion/baseimage for its zombie reaping capabilities but were
concerned about the size and having to port it to Debian.

I happen to have written a tool just for that. It's called tini, and it's
used in a few official Docker images (see here:
https://github.com/docker-library/official-images#init). You might want
to have a look.

If you're curious; you can find it here on Github:
https://github.com/krallin/tini


Reply to this email directly or view it on GitHub
#24 (comment)
.

@parente
Copy link
Member Author

parente commented Sep 10, 2015

@krallin thanks for sharing! I will definitely look into it.

@parente
Copy link
Member Author

parente commented Sep 17, 2015

Started a branch with tini replacing supervisord. Works as advertised. I need to beat up each image a bit more to ensure there's no surprises.

One point worth clarifying: we're still going to have to set tini to run as root in the images, not because it needs to do so but because our start-notebook.sh script supports options that require root privileges, namely the jovyan UID switch and granting sudo.

@jakirkham
Copy link
Member

Sounds cool. I've been trying out tini, as well. I'd be curious to know what you find out from your stress tests, @parente.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants