Git Product home page Git Product logo

nbviz-to-container's Introduction

nbviz-to-container

A containerization example that takes a interactive visualization in a Jupyter notebook and turns it in to a containerized web server

Prerequisites

Note: If Docker is already installed there is a container image available that contains everything else

In order to work through this example on your local machine make sure you have installed the following programs:

Notebook Example

Please use the walkthrough.ipynb file for an interactive example that takes an existing notebook and creates a web server running in a container to display an interactive visualization.

How to get started

Note: There is a section on creating a GitHub Action to build the container and push it to Docker Hub. This requires a GitHub account, a Docker Hub account, and for the example repository to be forked.

Via Docker

There is a container image available that contains all the prerequisites. Please note it is run via Docker, but only Podman is available to build inside the container.

docker run --privileged -p 8888:8888 docker.io/ncote/podman-notebook:2024-06-20 jupyter lab --ip 0.0.0.0

When it starts there will be a link displayed that starts with http://127.0.0.1:8888/lab?token=. This link must be used to launch the application as it contains a required security token. Once inside the Jupyter Lab session this repository, or a forked version, needs to be cloned. This can be done via the Terminal included in Jupyter Lab or via an extension. More information on how to use the Git extension can be found at this link to jupyterlab-git GitHub. Once the repository contents have been added open the nbviz-to-container directory and the walkthrough.ipynb to follow the rest of the content.

Via personal computer

Run the following in a terminal/command line. Use the Operating Systems search function to look for terminal if this is unfamiliar.

git clone https://github.com/NicholasCote/nbviz-to-container.git

The best way to run the content is inside a Jupyter environment. Jupyter Lab is more robust than Notebook, but either can be used. Change the directory to be inside the git repository

cd nbviz-to-container

jupyter lab walkthrough.ipynb

This should start a Jupyter Lab session with the walkthrough notebook which can be used to ensure the perquisites that haven't been used yet are installed prior to starting the content.

Note: If additional software is required after Jupyter Lab is started it may need to be restarted in a new terminal session to make sure it can use the newly installed applications.

nbviz-to-container's People

Contributors

nicholascote avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.