22 Manual Installation
Jothi Prasath edited this page 2024-03-11 12:44:12 +05:30

Manual installation on Linux or MacOS

If you want to manually install Calibre-Web (“from source”), follow the procedure below.

  1. Make sure you have installed pip and also venv for your python version. If missing, install it by the package manager of your distribution (e.g., apt for debian like distributions)

    • sudo apt install python3-pip python3-venv
  2. Go to the folder where you want to install Calibre-Web, e.g.,

    • cd /opt/calibre-web
  3. Create virtual environment for calibre web in the current folder

    • python3 -m venv venv
  4. Download and extract Calibre-Web into the current folder (in this example /opt/calibre-web) from the releases page on Github

  5. Install dependencies by running

    • ./venv/bin/python3 -m pip install -r requirements.txt
  6. Execute the command:

    • ./venv/bin/python3 cps.py (or nohup ./venv/bin/python3 cps.py - recommended if you want to exit the terminal window)

Issues on Raspberry Pi Raspberry Pi OS: Depending on your version of pip it's possible that the installation fails with Failed to build cryptography ERROR: Could not build wheels for cryptography, which is required to install pyproject.toml-based projects. In this case please try to update pip with ./venv/bin/python3 -m pip install --upgrade pip first, and then try installing Calibre-Web again. If this isn't working please also install cargo via sudo apt install cargo, and try again to install Calibre-Web.

Issues with Ubuntu: Please note that running the above install command can fail on some versions of Ubuntu, saying "can't combine user with prefix". This is a known bug and can be remedied by using the command ./venv/bin/python3 -m pip install --system -r requirements.txt instead.

Remark: All config files (settings database, log files) are stored in Calibre-Web root folder (in this example /opt/calibre-web). Additional config files, such as the config files for gdrive and gmail have to be placed there too.

Manual installation on Windows

For Windows pip and venv come with the basic installation. On Windows, the python binary can be found after installing the virtual environment under .\venv\script\python3.exe.

  1. Download and install the newest python version for windows from here: https://www.python.org/downloads/windows/

  2. Start an command prompt via "cmd". Go to the folder where you want to install Calibre-Web, e.g., c:\calibre-web

  3. Create virtual environment for calibre web in folder venv. The python installation in the example is c:\python

    • c:\python\python.exe -m venv venv
  4. Download and extract Calibre-Web into the current folder (in this example c:\calibre-web) from the releases page on Github

  5. Install dependencies by running .\venv\script\python3.exe -m pip install -r requirements.txt (executed from c:\calibre-web folder)

  6. Execute the command: .\venv\script\python3.exe cps.py

Remark: All config files (settings database, log files) are stored in Calibre-Web root page (in this example c:\calibre-web). Additional config files, such as the config files for gdrive and gmail have to be placed there too.