*Important* : You need to know what port to assign...
So at the moment (could be greatly improved). Make a copy of the make_user_accounts.py script, and run it like:
```python
python3 make_user_accounts --port $PORT --from-file usersnames.txt --passwords passwords.txt --addusers
```
I think i'm almost there.
The script ran fine, the user "david" is there, with a password.
Now i will check nginx if port 9070 is added, and if not, if after adding it to the conf it will work. Fingers crossed!
Nice!
I think i'm almost there.
The script ran fine, the user "david" is there, with a password.
Now i will check nginx if port 9070 is added, and if not, if after adding it to the conf it will work. Fingers crossed!
However ... Port 9070 was already in use.
Looking now for the place where the Jupyter ports can be edited ...
I ran the following command and this worked:
`python3 make_user_accounts.py --port 9070 --from-file usernames.txt --passwords passwords.txt --addusers`
However ... Port 9070 was already in use.
Looking now for the place where the Jupyter ports can be edited ...
Hmm, is there another file where the port needs to be changed?
I get a 404 now on the /__lab__/ page of the new user.
I tried to restart with sudo systemctl restart jupyterlab@USERNAME, but without success.
sudo systemctl status jupyterlab@* says that the instance is active ...
Hmm, is there another file where the port needs to be changed?
I get a 404 now on the `/__lab__/` page of the new user.
I tried to restart with `sudo systemctl restart jupyterlab@USERNAME`, but without success.
`sudo systemctl status jupyterlab@*` says that the instance is `active` ...
Trying to make a new user for David, as he is doing a workshop with the students tomorrow.
Important : You need to know what port to assign...
So at the moment (could be greatly improved). Make a copy of the make_user_accounts.py script, and run it like:
Nice!
I think i'm almost there.
The script ran fine, the user "david" is there, with a password.
Now i will check nginx if port 9070 is added, and if not, if after adding it to the conf it will work. Fingers crossed!
OK, cool!
It worked!
The last step was to copy the nginx settings of the new user to the configuration file there.
I ran the following command and this worked:
python3 make_user_accounts.py --port 9070 --from-file usernames.txt --passwords passwords.txt --addusers
However ... Port 9070 was already in use.
Looking now for the place where the Jupyter ports can be edited ...
Found it!
It was in:
~/.jupyter/jupyter_notebook_config.py
Yes, indeed, so all good (just make sure they match in the nginx)
Hmm, is there another file where the port needs to be changed?
I get a 404 now on the
/__lab__/
page of the new user.I tried to restart with
sudo systemctl restart jupyterlab@USERNAME
, but without success.sudo systemctl status jupyterlab@*
says that the instance isactive
...oh yeah this is a silly bug that I did as well, you need to rename "sandbot" to "sandbox" in the .jupyter/jupyter_notebook_config.py :o
TODO: Add a variables for the servername / url in the make script + adjust templates to use them!: Created #6
Ahhh! Oke that is an important detail :---).
Will change it now and see if it works.