LightYear
/Docs
DocsComputeRun Jupyter Notebook on a GPU Server

Run Jupyter Notebook on a GPU Server

Launch a Jupyter Notebook server on your GPU instance and access it securely from your browser.

intermediate
8 min read
LightYear Team
Updated April 24, 2026
jupytergpupythonnotebook
Ready to get started?

Prerequisites

  • A running LightYear GPU server
  • Python 3.10+ installed
  • Port 8888 open in your firewall group

Step 1 — Install Jupyter

>_BASH
$pip3 install jupyterlab

Step 2 — Generate a Config File

>_BASH
$jupyter lab --generate-config

Step 3 — Set a Password

>_BASH
$jupyter lab password
$# Enter and confirm a password

Step 4 — Configure Remote Access

Edit ~/.jupyter/jupyter_lab_config.py:

PYTHON
c.ServerApp.ip = '0.0.0.0'
c.ServerApp.port = 8888
c.ServerApp.open_browser = False
c.ServerApp.allow_root = True

Step 5 — Open the Firewall

In the LightYear control panel, add a firewall rule:

ProtocolPortSource
TCP8888Your IP (e.g. 203.0.113.0/32)

Step 6 — Start Jupyter Lab

>_BASH
$jupyter lab --no-browser &

Access at: http://<SERVER_IP>:8888

Running as a systemd Service

INI
# /etc/systemd/system/jupyter.service
[Unit]
Description=Jupyter Lab
After=network.target

[Service]
Type=simple
User=root
ExecStart=/usr/local/bin/jupyter lab --no-browser
Restart=on-failure

[Install]
WantedBy=multi-user.target
>_BASH
$systemctl daemon-reload
$systemctl enable jupyter
$systemctl start jupyter

Using SSH Tunnelling (More Secure)

Instead of opening port 8888 publicly, tunnel via SSH:

>_BASH
$ssh -L 8888:localhost:8888 root@<SERVER_IP>

Then access http://localhost:8888 on your local machine.

Was this article helpful?

Your cookie choices for this website

This site uses cookies and related technologies, as described in our privacy policy, for purposes that may include site operation, analytics, and enhanced user experience. You may choose to consent to our use of these technologies, or manage your own preferences. Cookie policy