Skip to content

Instantly share code, notes, and snippets.

@gtirloni
Last active May 6, 2023 14:18
Show Gist options
  • Save gtirloni/d4c3ffcce107b6ee79e2b50c0e0e8683 to your computer and use it in GitHub Desktop.
Save gtirloni/d4c3ffcce107b6ee79e2b50c0e0e8683 to your computer and use it in GitHub Desktop.
Start Jupyter-lab automatically
[Unit]
Description=JupyterLab
After=network-online.target
Wants=network-online.target
[Service]
ExecStart=/usr/bin/jupyter lab --no-browser
Restart=on-failure
RestartSec=7
RestartPreventExitStatus=3
[Install]
WantedBy=default.target
$ vi $HOME/.config/systemd/user/jupyter-lab.service
$ systemctl --user daemon-reload
$ systemctl --user enable jupyter-lab
$ systemctl --user start jupyter-lab
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment