Search code examples
pythonubuntucherrypy

Python 3.5.2 Installation of Cherrypy with apt


i developed a small web APP with CherryPy for Python. I want to run this on a production Server with ubuntu 16.04. My Sysadmin tells me that I shall not use pip or github repository, because of ... something wrong with using anything but apt ... he says.

Is there a way of getting a recent cherrypy for python3 with apt ?


Solution

  • The solution on Ubuntu 16.04 with python3 (Python 3.5.2):

    Install virtualenvironment for python3

    sudo apt-get install python3-venv

    Create a folder for your environment

    mkdir environment

    Create the environment

    python3 -m venv environment

    Change into folder

    cd environment/bin

    Activate environment

    source activate

    Install pip within the env

    apt install python3-pip

    Install cherrypy >= 18.1.0

    pip3 install cherrypy

    Run program

    python3 ./my_python_script.py