Sign inSign up

squawk/cds

By squawk

•Updated almost 9 years ago

content directory server.

Image
0

2.4K

squawk/cds repository overview

Build Status

** this software is still under development, its not recommended to use it now. **

⁠Content Directory Server (CDS)

⁠about

the squawk content directory server (CDS) serves mediafiles from the local storage. the mediafile are enriched with local and remote metadata.

⁠install the server

⁠install binary package
⁠use docker image
⁠install from source

To install the server from source you need cmake and a recent c++ (C++14) compiler installed. The developmeent packages of the dependencies must be available to the compiler.

⁠install dependencies on ubuntu
⁠get the source
⁠compile
⁠install

⁠usage

start the content directory server from the command line:

cds [OPTION...]
⁠options
namevaluedescription
--directoryPATHpath to the directory with the mediafiles. Multiple entries will result in a list containing all directories.
--listenIPAPI Webserver IP-Adress to bind to.
--http-portPORTAPI Webserver IP Port to bind to.
--tmp-directoryPATHtemporary folder for the thumbnails.
--tmdb-keyKEYAPI key for tmdb.
--amazon-access-keyKEYAccess key for amazon.
--amazon-keyKEYAPI key for amazon.
--redisHOSTRedis Database (default: localhost) (default: localhost)
--redis-portPORTRedis Database port (default: 6379) (default: 6379)
--helpPrint help

⁠api

⁠Base URL

all the requests have the base url of your server: http://<SERVER_IP>:<PORT>

⁠access the directory

the directory is structured as a tree. the content can be traversed from the root node. beside of the class specific attributes, the node will always contain the key, parent and cls attributes.

⁠load the child elements of a node.
GET /{node}/nodes
⁠parameters:
namevaluedescription
node{key}select from which parent node the list is created. root, for the keys file, ebook, movie, album, serie, artist and image the type collection is returned.
⁠query paremeters:
namevaluedescription
sortalpha, timestampsort list alphanumerical or by last access timestamp.
orderasc, descsort ascending or descending. default ist ascending.
filtertagfilter results by tag.
index{digit}start index of the result list.
count{digit}number of results in the result list.
⁠node

GET /{digit}

⁠keywords

GET /[ebook|movie|album|serie|artist|image]/name|{keyword}

⁠manage the server
⁠rescan the database.
GET rescan
⁠query paremeters:
namevaluedescription
flushtrue, falseflush the database before import the files.

⁠remote metadata providers:

for information retrievel the following database services can be used:

⁠dependencies:

binary dependencies needs to be installed on the target system.

these libraries will be downloaded and staticaly linked during the compile process.

  • asio⁠ is a cross-platform C++ library for network and low-level I/O programming that provides developers with a consistent asynchronous model using a modern C++ approach.
  • cxxopts⁠, lightweight C++ command line option parser
  • format::fmt⁠, small, safe and fast formatting library
  • rapidjson⁠, a fast JSON parser/generator for C++ with both SAX/DOM style API
  • RapidXML NS⁠ library - RapidXML with added XML namespaces support
  • re2⁠ is a fast, safe, thread-friendly alternative to backtracking regular expression engines like those used in PCRE, Perl, and Python. It is a C++ library.
  • redox⁠, modern, asynchronous, and wicked fast C++11 client for Redis
  • spdlog⁠, super fast C++ logging library.

⁠licence:

Tag summary

Content type

Image

Digest

Size

36.5 MB

Last updated

almost 9 years ago

docker pull squawk/cds