setup documentation for jupyterpi
Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.
 
 
 
 
manetta 16a83ac8a1 switch from notebook.auth to jupyter_server.auth pirms 2 mēnešiem
html Update 'html/INSTALLATION_NOTES.md' pirms 3 gadiem
templates Add 'templates/lab.conf' pirms 3 gadiem
README.md edit in lab.conf is needed pirms 2 mēnešiem
make_user_accounts.py changing the "shared" symlink into "www" pirms 2 mēnešiem
reset_jupyter_password.py switch from notebook.auth to jupyter_server.auth pirms 2 mēnešiem

README.md

First the following software needs to be installed:

pip3 install jupyterlab notebook

First copy the service file template to /etc/systemd/system:

sudo cp templates/jupyterlab@.service /etc/systemd/system

And then the lab.conf nginx configuration file to /etc/nginx/includes/:

sudo nano templates/lab.conf (change sandbot to the servername) sudo mkdir /etc/nginx/includes sudo cp templates/lab.conf /etc/nginx/includes/

Now you can use the make_user_accounts.py script with the following scripts:

  • --passwords: words.txt -- a txt file with ingredient words on each line to generate passwords with
  • --from_file: users.txt -- a txt file with a username on each line
  • --servername: sandbol -- a string

The script generates:

  • users.csv: a list of all the users, their personal ports, their passwords
  • users.md: a bulletpoint list with a link to the /__LAB__/ link for each user
  • users.nginx.conf: snippets of nginx configuration that can be added to the main nginx config file

This service file is a template for all the jupyter lab services that are running, which is one for each user.

Now add the generated nginx configurations for each jupyterlab instance:

cat users.nginx.conf sudo nano /etc/nginx/sites-available/default

And convert the markdown into HTML to add links to the index page:

pandoc users.md -o users.html

Now try to start one jupyterlab instance with:

sudo systemctl start jupyter@murtaugh