We've created a Dockerized version of the notebook that can be run locally on your machine. This methodology has been tested on MacOS, running Docker Desktop, and using Chrome to interact with JupyterLab.
-
Clone the notebook repo to your local machine:
git clone https://github.com/everactive/python-notebook-sample.git -
Open a terminal and navigate to the root directory of the cloned repo.
-
Run
./build.shto build the Docker container. The Docker build may take several minutes to complete. -
Once the Docker image is built, run
./run.shto start the container. The run script will automate setup of the Docker container and JupyterLab server for you, and will expose the notebook so that you can interact with it via a local web browser on your computer.Note that you can supply your Everactive API credentials when invoking the run script (as opposed to providing the credentials in the notebook itself). To do so, include the
EVERACTIVE_CLIENT_IDandEVERACTIVE_CLIENT_SECRETenvironment variables in the script invocation command:EVERACTIVE_CLIENT_ID=xxxxxxx EVERACTIVE_CLIENT_SECRET=xxxxxxx ./run.sh -
When the script pauses after starting JupyterLab within Docker, you'll see the following output in the terminal:
-
Copy and paste the full localhost URL into your web browser of choice. In the example above, you would use the following URL:
http://127.0.0.1:8888/lab?token=e29f27bfc09d20126bc7256b6a2dec4bbfc093c4079554fcNote that the JupyterLab URL token will change each time you rerun the Docker container.
-
Double click on the notebook name in the left-hand file browser menu to open it.
-
If you receive a dialog box prompting you to select a kernel, select the
everactive-envpluskernel. -
At this point, you are ready to run the notebook. Go forth and explore!
-
When you are done, close the web browser and return to the run script in the terminal. Press
Enterto shut down the Docker container.




