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

New docker stack for a headless kernel #42

Merged
merged 7 commits into from
Jan 13, 2016

Conversation

poplav
Copy link
Contributor

@poplav poplav commented Oct 9, 2015

New docker stack for a headless kernel. It uses the new kernel gateway from the Jupyter incubator project to provide websocket access without exposing the whole notebook UI.

I created the stack to be able to test the kernel gateway. Submitting it here for possible future inclusion into the official docker-stacks, and maybe to open up the discussion about kernel containers.

@parente
Copy link
Member

parente commented Oct 9, 2015

@poplav Can you put a bit of text in the commit and/or on the PR so that folks know what this is and it can be discussed? Thanks!

@poplav poplav changed the title Added kernel gateway New docker stack for a headless kernel Oct 9, 2015
@parente
Copy link
Member

parente commented Oct 12, 2015

Thanks. I'd like to hold off for a little bit on merging this until the kernel_gateway matures a bit more. It might be good to point out in the README that it's a jupyter incubator project at the moment.

@rgbkrk thoughts?

@rgbkrk
Copy link
Member

rgbkrk commented Oct 12, 2015

Yeah I think putting this dockerfile on the incubator itself would be good.

@parente
Copy link
Member

parente commented Oct 12, 2015

@rgbkrk Just to clarify, I do believe we should have a set of stacks here with kernels eventually (minimal-kernel, python-kernel, r-kernel, ...). I was only commenting on not wanting to send the wrong message that it's stable and ready to use by merging it today. Do you agree?

@rgbkrk
Copy link
Member

rgbkrk commented Oct 12, 2015

Totally in sync there. Once we prove it out, we can put it here which tends to get interpreted as stable (or should be).

@parente
Copy link
Member

parente commented Nov 18, 2015

So kernel_gateway 0.1.0 is now out on pypi and pip installable. It's already runnable with the jupyter/minimal-notebook image.

@poplav it would be great if you could revisit this PR now and just pip install jupyter_kernel_gateway==0.1.0. We can then start to test the container and see how to tidy it up (e.g., I see pandoc remains and probably shouldn't).

@parente parente changed the title New docker stack for a headless kernel [WIP] New docker stack for a headless kernel Dec 11, 2015
…y to provide websocket access without exposing the whole notebook UI.

Contribution (c) Copyright IBM Corp. 2015
…gateway-*.tar.gz

Contribution (c) Copyright IBM Corp. 2015
@poplav poplav force-pushed the minimal_kernel branch 8 times, most recently from 4590bac to e4400ea Compare January 11, 2016 20:20
Contribution (c) Copyright IBM Corp. 2016

# Configure environment
ENV SHELL /bin/bash
ENV NB_USER jovyan
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure we even need the jovyan user. Try using nobody which should exist in the container.

Contribution (c) Copyright IBM Corp. 2016
EXPOSE 8888
WORKDIR /home/$NB_USER/work
ENTRYPOINT ["tini", "--"]
CMD ["/usr/local/bin/start-notebook.sh"]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't want to run start-notebook.sh. Entrypoint should be something like the one over the kernel gateway demos like tini -- jupyter kernel_gateway and the CMD is --ip=0.0.0.0

Contribution (c) Copyright IBM Corp. 2016
# Configure container startup
USER $NB_USER
EXPOSE 8888
WORKDIR /home/$NB_USER/work
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nobody probably has no home dir. Maybe run in /tmp by default?

# Kernel Gateway Stack

## What it Gives You
* [Jupyter Kernel Gateway](https://github.com/jupyter-incubator/kernel_gateway) that spawns minimal Jupyter Python kernel
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"that enables programmatic access to kernels" maybe?

Contribution (c) Copyright IBM Corp. 2016
Contribution (c) Copyright IBM Corp. 2016
@poplav
Copy link
Contributor Author

poplav commented Jan 12, 2016

The images size at commit b89f25d is 485.3 MB.

@rgbkrk
Copy link
Member

rgbkrk commented Jan 12, 2016

Pretty slim, all things considered.

@poplav poplav changed the title [WIP] New docker stack for a headless kernel New docker stack for a headless kernel Jan 12, 2016
@parente
Copy link
Member

parente commented Jan 12, 2016

I think this is good to go in. We can iterate over time. I'll merge this in later after setting up a second PR that updates the Makefile to make sure this new stack builds alongside the notebook based ones properly.

parente added a commit that referenced this pull request Jan 13, 2016
New docker stack for a headless kernel
@parente parente merged commit 0acf4f0 into jupyter:master Jan 13, 2016
@parente
Copy link
Member

parente commented Jan 13, 2016

🎈

@parente
Copy link
Member

parente commented Jan 13, 2016

Tagged e7c2515ad9b2 and pushed to Docker Hub.

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

Successfully merging this pull request may close these issues.

3 participants