All Projects → seblucas → Cops

seblucas / Cops

Licence: gpl-2.0
Calibre OPDS (and HTML) PHP Server : web-based light alternative to Calibre content server / Calibre2OPDS to serve ebooks (epub, mobi, pdf, ...)

Labels

Projects that are alternatives of or similar to Cops

Py regular expressions
Learn Python Regular Expressions step by step from beginner to advanced levels
Stars: ✭ 770 (-31.86%)
Mutual labels:  ebook
Webstore
Package of applications allowing to compress HTML content into a single application together with a simple web browser (e-books alternative)
Stars: ✭ 7 (-99.38%)
Mutual labels:  ebook
Shellman Ebook
Guide on shell scripting with Shellman vscode snippet
Stars: ✭ 50 (-95.58%)
Mutual labels:  ebook
Packt Publishing Free Learning
Scripts that automatically claim and download free daily eBooks from https://www.packtpub.com/packt/offers/free-learning
Stars: ✭ 788 (-30.27%)
Mutual labels:  ebook
Buka
Buka is a modern software that helps you manage your ebook at ease.
Stars: ✭ 896 (-20.71%)
Mutual labels:  ebook
Fundamentals Of Python Data Structures
《数据结构(Python语言描述)》"Fundamentals of Python:Data Structures" 电子书和配套代码
Stars: ✭ 30 (-97.35%)
Mutual labels:  ebook
Running Elasticsearch Fun Profit
A book about running Elasticsearch
Stars: ✭ 664 (-41.24%)
Mutual labels:  ebook
Ebook Building An Api Backend With Microprofile
Building an API Backend with MicroProfile
Stars: ✭ 53 (-95.31%)
Mutual labels:  ebook
Network Programming With Go
Network programming with Go
Stars: ✭ 903 (-20.09%)
Mutual labels:  ebook
Geektime dl
把极客时间装进 Kindle,内含快手内推等福利
Stars: ✭ 1,033 (-8.58%)
Mutual labels:  ebook
Ebookcoin
Ebookcoin has been updated to DDN Blockchain,please get it from https://github.com/ddnlink/ddn
Stars: ✭ 789 (-30.18%)
Mutual labels:  ebook
Tools
The Standard Ebooks toolset for producing our ebook files.
Stars: ✭ 827 (-26.81%)
Mutual labels:  ebook
Save As Ebook
Save a web page/selection as an eBook (.epub format) - a Chrome/Firefox/Opera Web Extension
Stars: ✭ 959 (-15.13%)
Mutual labels:  ebook
Pbr White Paper
⚡️基于物理的渲染(PBR)白皮书 | White Paper of Physically Based Rendering(PBR)
Stars: ✭ 780 (-30.97%)
Mutual labels:  ebook
Koreader
An ebook reader application supporting PDF, DjVu, EPUB, FB2 and many more formats, running on Cervantes, Kindle, Kobo, PocketBook and Android devices
Stars: ✭ 9,467 (+737.79%)
Mutual labels:  ebook
Ethereum Development With Go Book
📖 A little book on Ethereum Development with Go (golang)
Stars: ✭ 754 (-33.27%)
Mutual labels:  ebook
Netkiller.github.io
Netkiller Free ebook - 免费电子书
Stars: ✭ 861 (-23.81%)
Mutual labels:  ebook
Freecad mod dev guide
Ebook: Module developer's guide to FreeCAD 's source code
Stars: ✭ 55 (-95.13%)
Mutual labels:  ebook
Awesome Ebooks
收录开源的经典技术书籍 PDF 文件及相关网站,持续更新中...
Stars: ✭ 51 (-95.49%)
Mutual labels:  ebook
Nes ebook
A mini book on writing NES emulator using rust lang
Stars: ✭ 38 (-96.64%)
Mutual labels:  ebook

COPS

COPS stands for Calibre OPDS (and HTML) Php Server.

See : COPS's home for more details.

Don't forget to check the Wiki.

Scrutinizer Code Quality

Code Coverage

Build Status / Scrutinizer

Build Status

Selenium Test Status

Why ?

In my opinion Calibre is a marvelous tool but is too big and has too much dependencies to be used for its content server.

That's the main reason why I coded this OPDS server. I needed a simple tool to be installed on a small server (Seagate Dockstar in my case).

I initially thought of Calibre2OPDS but as it generate static file no search was possible.

Later I added an simple HTML catalog that should be usable on my Kobo.

So COPS's main advantages are :

  • No need for many dependencies.
  • No need for a lot of CPU or RAM.
  • Not much code.
  • Search is available.
  • It was fun to code.

If you want to use the OPDS feed don't forget to specify feed.php at the end of your URL.

You just have to sync your Calibre directory to your COPS server the way you prefer (Dropbox, Bt Sync, Syncthing, use a directory shared with Nextcloud, ...).

Prerequisites

  1. PHP 5.3, 5.4, 5.5, 5.6, 7.X or hhvm with GD image processing, Libxml, Intl, Json & SQLite3 support (PHP 5.6 or later recommended).
  2. A web server with PHP support. I tested with various version of Nginx and Apache. Other people reported it working with Apache and Cherokee. You can also use PHP embedded server (https://github.com/seblucas/cops/wiki/Howto---PhpEmbeddedServer)
  3. The path to a calibre library (metadata.db, format, & cover files).

On any Debian based Linux you can use : apt-get install php5-gd php5-sqlite php5-json php5-intl

If you use Debian Stretch : apt-get install php7.0-gd php7.0-sqlite3 php7.0-json php7.0-intl php7.0-xml php7.0-mbstring php7.0-zip

On Centos you may have to add : yum install php-xml

Install a release (Easiest way)

  1. Extract the zip file you got from the release page to a folder in web space (visible to the web server).
  2. If you're doing a first-time install, copy config_local.php.example to config_local.php
  3. Edit config_local.php to match your config.
  4. If needed add other configuration item from config_default.php

If you like Docker, you can also try this multiarch docker container from linuxserver.io It has builds for x64, armhf and arm64.

Install from sources

git clone https://github.com/seblucas/cops.git # or download lastest zip see below
cd cops
wget https://getcomposer.org/composer.phar
php composer.phar global require "fxp/composer-asset-plugin:~1.1"
php composer.phar install --no-dev --optimize-autoloader

After that you can use the previous how-to starting at the second step.

Note that instead of cloning you can also get latest master as zip

Note that if your PHP version is lower that 5.6, then you may have to remove composer.lock before starting the last line.

Where to put my Calibre directory ?

Long story short : ALWAYS outside of COPS's directory especially if COPS is installed on a VPS / Server. If you follow my advice then your data will be safe.

If you choose to put your Calibre directory inside your web directory and use Nginx then you will have to edit /etc/nginx/mime.types to add these lines :

application/epub+zip epub;
application/x-mobipocket-ebook mobi prc azw;

Known problems

Not a lot, except for the bad quality of the code (first PHP project ever) ;)

Please see https://github.com/seblucas/cops/issues for open issues

Need help

Please read https://github.com/seblucas/cops/wiki and check the FAQ.

Contributing

As you could see here, I appreciate every contributions and there were a lot over time. So don't be shy and submit your Pull Requests.

Note to translators : please prefer using Transifex instead of doing a PR.

I only have one limit (I may have more but that one is the worse) : COPS' goal is to provide an alternative to Calibre's content server and not to replace Calibre entirely. So I will refuse any PR making changes to the database content.

Credits

External libraries used :

Copyright & License

COPS - 2012-2019 (c) Sébastien Lucas

See COPYING and file headers for license info

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].