Calibre-Web is a web app that offers a clean and intuitive interface for browsing, reading, and downloading eBooks using a valid Calibre database.
This software is a friendly fork of Calibre-Web designed to be run inside of an Internet-in-a-Box.
- Mainline Calibre-Web features
- Not just books but also learning videos, audiocasts and images most needed by your community or family
- Downloading online media
-
If you don't have an existing IIAB, start here:
https://github.com/iiab/calibre-web/wiki#wrench-installation
-
Installing on an existing Internet-in-a-Box (IIAB):
https://github.com/iiab/iiab/blob/master/roles/calibre-web/README.rst
- Read the NEW Install Instructions above for IIAB Calibre-Web!
- Access Calibre-Web: Open your browser and navigate to:
or for the OPDS catalog:
http://localhost:8083
http://localhost:8083/opds
- Log in: Use the default admin credentials:
- Username: Admin
- Password: changeme
- Database Setup: If you do not have a Calibre database, download a sample from:
Move it out of the Calibre-Web folder to avoid overwriting during updates.
https://github.com/iiab/calibre-web/raw/master/library/metadata.db
- Configure Calibre Database: In the admin interface, set the
Location of Calibre database
to the path of the folder containing your Calibre library (wheremetadata.db
is located) and click "Save". - Google Drive Integration: For hosting your Calibre library on Google Drive, refer to the Google Drive integration guide.
- Admin Configuration: Configure your instance via the admin page, referring to the Basic Configuration and UI Configuration guides.
- IIAB: IIAB Calibre-Web is designed for running on top of an Internet-in-a-Box install
- Python Version: Ensure you have Python 3.7 or newer.
- Imagemagick: Required for cover extraction from EPUBs. Windows users may also need to install Ghostscript for PDF cover extraction.
- Optional Tools:
- Calibre desktop program: Recommended for on-the-fly conversion and metadata editing. Set the path to Calibre’s converter tool on the setup page.
- Kepubify tool: Needed for Kobo device support. Download the tool and place the binary in
/opt/kepubify
on Linux orC:\Program Files\kepubify
on Windows.
IIAB Calibre-Web does not support Docker.
We would like to thank all the contributors and maintainers of Calibre-Web for their valuable input and dedication to the project. Your contributions are greatly appreciated:
You can find the current test plan under in the features directory. Currently, there is only one test plan, which is basic_behavior.feature.
Here what the layout of an example test plan looks like looks like:
Feature: Basic behavior
Testing basic behavior like showing home page and login
Scenario: Home Page
Given Calibre-Web is running
When I go to the home page
Then I should not see the error message
And see homepage information
A scenario is a specific test. Depending on the test, some things are taken as given, when an action is performed, then a certain state is reached.
The tests are implemented using pytest-splinter, pytest-bdd and Selenium. The gist of all of this is to say that these are tests using behavior-driven development. Pytest-splinter is the main driver of the tests, it is what is really driving the browser through the use of Selenium.
Currently, we are limited to using Firefox and Chrome as a result of Splinter (a dependency of pytest-splinter) not supporting Chromium. If this were to change in the future though, we would probably rather use Chromium over Chrome as that is the default browser used with Raspberry Pi.
You can see tests in the /tests/functional directory. Currently there is only one test file, test_basic_behavior.py.
Here is an example of one test:
@scenario('basic_behavior.feature', 'Home Page')
def test_home_page():
"""Home Page."""
@given('Calibre-Web is running')
def _(step_context):
"""Calibre-Web is running."""
step_context['ip_address'] = 'localhost:8083'
@when('I go to the home page')
def _(browser, step_context):
"""I go to the home page."""
url = urljoin("".join(['http://', str(step_context['ip_address'])]), '/')
browser.visit(url)
@then('I should not see the error message')
def _(browser, step_context):
"""I should not see the error message."""
@then('see homepage information')
def _(browser):
"""see homepage information."""
print("!!!!!!!")
print(browser.title)
print(browser.url)
print("!!!!!!!")
assert browser.is_text_present('Books'), 'Book test'
If you compare this test to the test I showed you in this test plan, then you will see that is pretty much exactly the same. Especially pay attention to the fixtures (the lines that begin with @).
-
Install Chrome and/or Firefox to enable Selenium testing:
-
Install Chrome for Ubuntu and/or
-
Install Firefox [NB: If you are on Ubuntu Deskop you must remove the Firefox Snap with
sudo snap remove firefox
, or else the tests will fail]
-
-
Enter into the directory where Calibre-Web is located:
cd /usr/local/calibre-web-py3
-
Install the integration test requirements in the same virtual environment:
pip install -r integration-tests-requirements.txt
If you want to watch the test run
pytest -s --splinter-webdriver chrome
And/or you can just run headless:
pytest -s --splinter-webdriver chrome --splinter-headless
To run the tests with the Firefox browser instead, replace chrome with firefox.
To contribute, please check our Contributing Guidelines. We welcome issues, feature requests, and pull requests from the community.
If you encounter bugs or issues, please report them in the issues section of the repository. Be sure to include detailed information about your setup and the problem encountered.
If your problem is generic to the upstream janeczku/calibre-web you may wish to report your issue there.
We welcome suggestions for new features. Please create a new issue in the repository to discuss your ideas.
- Documentation: Comprehensive documentation is available on the IIAB Calibre-Web wiki and the upstream Calibre-Web wiki.
- Community Contributions: Explore the community contributions to see ongoing work and how you can get involved.
Thank you for using Calibre-Web! We hope you enjoy managing your eBook library with our tool.