How to Start a Simple Web Server in Python 3 on Mac. If you’re a Python user you may already be familiar with the handy trick that allows you to instantly create a simple web server using an easy command string entered in the command line of Mac OS. Hi Luke, you can add pythonw as a local interpreter in Settings-Python Interpreters and use it to run your program.
January 27, 2019, 3 min read
In this tutorial we’ll learn how to install and configure a remote Jupyter Notebook server on Ubuntu. A typical use case for this is having a desktop computer with a powerful GPU that you want to expose to other machines, like a laptop or a Mac, when working with Jupyter Notebooks.
Install Jupyter Notebook
The recommended way to install Jupyter Notebook is via Anaconda—if you already have it installed, then you also have Jupyter installed. See the official instructions for help.
Configure Jupyter Notebook to allow remote connections
By default, a Jupyter Notebook server runs locally at 127.0.0.1:8888 and is accessible only from localhost on http://127.0.0.1:8888. We’re going to change that to allow remote connections. As a security precaution, I recommend blocking incoming internet connection to the
8888 port on your router.
Create a config file
In terminal, type:
Set up a Jupyter Notebook password
You will have to enter this password whenever you access your Notebooks from a browser. In terminal, type:
You will see the following output:
Enable SSL
It’s a good idea to enable SSL when sharing your Jupyter Notebooks over the network. You’ll need a certificate for that. The easiest way is to create a self-signed certificate—the downside is that you’ll have to ignore your browser’s security warnings.
In terminal, type:
Edit the config file
The Jupyter Notebook config file
jupyter_notebook_config.py is in the ~/.jupyter directory. Open the file and change the following settings:
Start Jupyter Notebooks on boot
The last step is to ensure Jupyter Notebooks runs every time you boot Ubuntu. There are various ways you can achieve that. The easiest I’ve found is to add a cron job. In terminal, type
crontab -e to edit your cron jobs and add the following to the end of the file:
Conclusion
Congratulations! You can now use Jupyter Notebooks remotely and take advantage of your GPU. Remember to use
https when connecting to your Jupyter Notebook server (i.e. https://192.168.0.100:8888 ).
These are the boot options that are useful when starting Anaconda. For moreinformation refer to the appropriate Installation Guide for your release andto the Anaconda wiki.
Anaconda bootup is handled by dracut, so most of the kernel arguments handledby dracut are also valid. See dracut.kernel(7) for details on those options.
Throughout this guide, installer-specific options are prefixed with
inst (e.g. inst.ks ). Options specified without the inst prefix arerecognized, but the prefix may be required in a future release.
Installation Source¶
Note
An installable tree is a directory structure containing installerimages, packages, and repodata. [1]
Usually this is either a copy of the DVD media (or loopback-mounted DVDimage), or the
<arch>/os/ directory on the Fedora mirrors.
inst.repo¶
This gives the location of the Install Source - that is, the place where theinstaller can find its images and packages. It can be specified in a fewdifferent ways:
Comments are closed.
|
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |