Secure Your Jupyter Server
Here we set up Jupyter with SSL and a custom password.
Connect to the Amazon EC2 instance, and then complete the following procedure.
Configure the Jupyter server
-
Jupyter provides a password utility. Run the following command and enter your preferred password at the prompt.
$
jupyter notebook passwordThe output will look something like this:
Enter password: Verify password: [NotebookPasswordApp] Wrote hashed password to /home/ubuntu/.jupyter/jupyter_notebook_config.json
-
Create a self-signed SSL certificate. Follow the prompts to fill out your locality as you see fit. You must enter
.
if you wish to leave a prompt blank. Your answers will not impact the functionality of the certificate.$
cd ~$
mkdir ssl$
cd ssl$
openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout mykey.key -out mycert.pem
Note
You might be interested in creating a regular SSL certificate that is third party signed and does not cause the browser to give you a security warning.
This process is much more involved.
Visit Jupyter's documention
Next Step
Start the Jupyter notebook server