mduplouy / silex-cops

A port of COPS (Calibre OPDS PHP Server) under Silex micro framework
24 stars 9 forks source link

Silex-Cops

Description

Silex-Cops is a web based Ebook sharing (and later full management) software.

It's a port and enhancement of COPS (Calibre OPDS PHP Server) on the Silex micro framework.

Demo

A live demo is available at http://silex-cops.solocreation.com

You can play without limit, the database is reset once per hour

Why ?

Because like many people i use Calibre as library manager, but the html export doesn't suit my needs.

Because like many other people i took a look at Cops (https://github.com/seblucas/cops) but the way it's developped doesn't allow me to make the modifications i want beside the fact that i'm using PHP for now twelve years.

I also wanted to play with Silex micro-framework :D

What's new with this ?

The main goal is to provide a nicely designed software with good performances that can be hosted either on a small machine like a NAS at home or a real web hosting server. That's why i decided to create some kind of Cops but based on OOP good practices and relying on Silex (http://silex.sensiolabs.org), Twig template engine (http://twig.sensiolabs.org) and the Symfony 2 components.

Anyone with basic Silex / SF2 knowledge is able to modify, enhance and play with Silex-Cops.

Anyone comfortable with Twig can create a theme or modify the default one.

Available features

Requirements

First you will need a Calibre database

Silex-Cops works with PHP version >= 5.3

Please note that it is not intended to work on any Windows version, try at your own risks

The following PHP modules are required :

apc or opcache (opcode and data cache) are not required but highly recommended

Installation

The application is still under heavy development tough the book browsing feature is working well.

1. To install, first clone the repository :

git clone git@github.com:mduplouy/silex-cops.git

2. Get composer

$ curl -s https://getcomposer.org/installer | php

3. Install the dependencies using Composer :

$ cd silex-cops
$ php ../composer.phar install

4. Configure the app

Addtionnal configuration for synology users :

Do not forget to deny access to all files but the index.php and assets !

5. Configure HTTP authentication

By default the public part is protected by simple HTTP auth.

There is one builtin account

Note : You can change default password in config file and reinit database (see below)

Logins can be changed in the back office under "User management" section

6. Configure your web server

Your web server must point to the web/ directory of the app (DocumentRoot directive with Apache HTTP server)

Available commands

If you don't want your visitor to wait for thumbnails to be generated, do it using cli by running following command :

$ php app/console.php generate:thumbnails

Reset user account with the following command :

$ php app/console.php database:init

Index your database with algolia :

$ php app/console.php algolia:reindex

License

License for this is Do What The Fuck You Want To Public License, (http://www.wtfpl.net/about/) guess you don't need more explanations ;)

Troubleshooting & feature request

Open an issue on github ;)

Badges

Scrutinizer Quality Score

Code Coverage

Build Status

SensioLabsInsight