forked from boyska/sito-hackit-16
290 lines
12 KiB
HTML
290 lines
12 KiB
HTML
<!doctype html>
|
|
<html lang="en">
|
|
|
|
<head>
|
|
<meta charset="utf-8">
|
|
|
|
<title>Libreant: the general purpose media archive manager</title>
|
|
|
|
<meta name="description" content="Nasty code for nasty people!">
|
|
<meta name="author" content="Insomnia-lab">
|
|
|
|
<meta name="apple-mobile-web-app-capable" content="yes" />
|
|
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent" />
|
|
|
|
<link rel="stylesheet" href="css/reveal.css">
|
|
<link rel="stylesheet" href="css/theme/sky.css" id="theme">
|
|
|
|
<!-- For syntax highlighting -->
|
|
<link rel="stylesheet" href="lib/css/zenburn.css">
|
|
|
|
<!-- If the query includes 'print-pdf', use the PDF print sheet -->
|
|
<script>
|
|
document.write( '<link rel="stylesheet" href="css/print/' + ( window.location.search.match( /print-pdf/gi ) ? 'pdf' : 'paper' ) + '.css" type="text/css" media="print">' );
|
|
</script>
|
|
|
|
<!--[if lt IE 9]>
|
|
<script src="lib/js/html5shiv.js"></script>
|
|
<![endif]-->
|
|
</head>
|
|
|
|
<body>
|
|
|
|
<div class="reveal">
|
|
|
|
<!-- Any section element inside of this container is displayed as a slide -->
|
|
<div class="slides">
|
|
|
|
<section>
|
|
<h1>Libreant: </h1>
|
|
<h3>The general purpose media archive manager</h3>
|
|
<p>
|
|
<small>For more info:<a href="https://libreant.readthedocs.org/en/latest/">libreant.rtfd.org</a></small>
|
|
</p>
|
|
<img src="img/logo_black.png" alt="Logo" style="border-width:0; width:35%; background-color: transparent; box-shadow:0 0 0px">
|
|
</section>
|
|
|
|
<section>
|
|
<section>
|
|
<h2>Background</h2>
|
|
<h4>Insomnialab birth</h4>
|
|
<p>
|
|
Two years ago some people began to meet in Rome, in a local squat, inside Sapienza university.
|
|
There were exciting times and a new hacker space was born.
|
|
</p>
|
|
<br/>
|
|
<p class="fragment">
|
|
<code class="python">Insomnialab</code> is now two years old and is currently located inside the walls of Forte Prenestino,
|
|
after the eviction of the squat.
|
|
</p>
|
|
</section>
|
|
|
|
<section>
|
|
<h2>Background</h2>
|
|
<h4>Needs</h4>
|
|
<p>
|
|
In the Sapienza squat we contributed to the beginning of a project, called <em>Proprietà Pirata</em>. The goal was
|
|
to overcome the limits imposed by the copyright enforcement, primarily inside the university classes.
|
|
We realized that a lot of infoshops and in self-organized places (autonomous libraries, etc.) would benefit from
|
|
an <u>easy-to-use and federative software</u>.
|
|
</p>
|
|
</section>
|
|
|
|
<section>
|
|
<h2>Background</h2>
|
|
<h4>Existing software</h4>
|
|
<p>
|
|
We realized that there existed some FOSS solution:
|
|
</p>
|
|
<ul>
|
|
<li class="fragment"><b>Calibre</b><br/><small>desktop application, not suited for web managing</small></li>
|
|
<li class="fragment"><b>Colibrì</b><br/> <small>not ready at the time</small></li>
|
|
<li class="fragment"><b>PeerLibrary</b><br/> <small>designed specifically for academic papers</small></li>
|
|
</ul>
|
|
</section>
|
|
</section>
|
|
|
|
<section>
|
|
<section>
|
|
<h2>Reinventing the wheel</h2>
|
|
<h4>Libreant features</h4>
|
|
<ul>
|
|
<li class="fragment"><b>Node aggregator</b><br/><small>Give the possibility for some nodes to browse each other</small></li>
|
|
<li class="fragment"><b>webapp</b><br/><small>The interface, both for user and admin</small></li>
|
|
<li class="fragment"><b>Easy-to-use and customizable</b><br/><small></small></li>
|
|
</ul>
|
|
</section>
|
|
|
|
<section>
|
|
<h2>Architecture</h2>
|
|
<h4>Tools</h4>
|
|
<ul>
|
|
<li class="fragment"><b>Language</b>: python</li>
|
|
<li class="fragment"><b>Database</b>: elasticsearch + fsdb</li>
|
|
<li class="fragment"><b>web framework</b>: Flask</li>
|
|
</ul>
|
|
</section>
|
|
|
|
<section>
|
|
<h2>Architecture</h2>
|
|
<h4>How we built it</h4>
|
|
<ul>
|
|
<li><a href=./index.html#/2/3>Agherant</a> (aggregator)</li>
|
|
<li><a href=./index.html#/2/4>Preset/Templating</a></li>
|
|
<li><a href=./index.html#/2/5>Full text search (ES)</a></li>
|
|
<li><a href=./index.html#/2/6>Localization</a></li>
|
|
<li><a href=./index.html#/2/7>REST API</a></li>
|
|
<li><a href=./index.html#/2/8>CLI</a></li>
|
|
<li><a href=./index.html#/2/9>Modularity</a></li>
|
|
</ul>
|
|
</section>
|
|
|
|
<section>
|
|
<h2>Architecture</h2>
|
|
<h4>Agherant</h4>
|
|
<p>Pretty self-explanatory<br/>
|
|
<img src="img/graph.png" alt="a mesh graph" style="width:40%"></p>
|
|
<p><small><a href=./index.html#/2/2>Back</a></small></p>
|
|
</section>
|
|
|
|
<section data-markdown>
|
|
<script type="text/template">
|
|
## Architecture
|
|
#### Preset/Templating
|
|
```json
|
|
{"id":"book",
|
|
"description":"simple book",
|
|
"properties": [{ "id": "category",
|
|
"description": "book format",
|
|
"required": true,
|
|
"type": "enum",
|
|
"values": ["scientific","novel","children"]
|
|
},
|
|
{ "id": "title",
|
|
"description": "a required property",
|
|
"required": true
|
|
},
|
|
{ "id": "actors",
|
|
"description":"people who contributed to the creation of the work"
|
|
}],
|
|
"allow_upload": true}
|
|
```
|
|
[Back](./index.html#/2/2)
|
|
</script>
|
|
|
|
</section>
|
|
|
|
<section>
|
|
<h2>Architecture</h2>
|
|
<h4>Full text search</h4>
|
|
<p>Let's try it! <p>
|
|
<small><a href=./index.html#/2/2>Back</a></small></p>
|
|
</section>
|
|
|
|
<section>
|
|
<h2>Architecture</h2>
|
|
<h4>Localization</h4>
|
|
<p>We use Babel to allow for localization.</p>
|
|
<p>An example can be looked in the html skeletons</p>
|
|
<pre><code class="hljs html">
|
|
{%trans%}Sorry, no books matching your query{%endtrans%}
|
|
</code></pre>
|
|
<p><small><a href=./index.html#/2/2>Back</a></small></p>
|
|
</section>
|
|
|
|
<section data-markdown>
|
|
<script type="text/template">
|
|
## Architecture
|
|
#### REST API
|
|
```
|
|
GET /api/v1/volumes/<volume-id>
|
|
GET /api/v1/volumes/?q=staceppademinchia&size=2&from=5
|
|
POST /api/v1/volumes/
|
|
PUT /api/v1/volumes/<volume-id>/attachments/<attachments-id>
|
|
GET /api/v1/volumes/<volume-id-id>/attachments/<attachments-id>/file
|
|
```
|
|
#### [Back](./index.html#/2/2)
|
|
</script>
|
|
</section>
|
|
|
|
<section>
|
|
<h2>Architecture</h2>
|
|
<h4>CLI</h4>
|
|
<pre><code class="hljs bash">
|
|
Usage: libreant [OPTIONS]
|
|
|
|
launch libreant daemon
|
|
|
|
Options:
|
|
--version Show the version and exit.
|
|
-s, --settings <path> file from wich load settings
|
|
-d, --debug operate in debug mode
|
|
-p, --port <port> port on which daemon will listen
|
|
--address <address> address on which daemon will listen
|
|
--fsdb-path <path> path used for storing binary file
|
|
--es-indexname <name> index name to use for elasticsearch
|
|
--es-hosts <host>.. list of elasticsearch nodes to connect to
|
|
--preset-paths <path>.. list of paths where to look for presets
|
|
--agherant-descriptions <url>..
|
|
list of description urls of nodes to
|
|
aggregate
|
|
--help Show this message and exit.
|
|
</code></pre>
|
|
<p><small><a href=./index.html#/2/2>Back</a></small></p>
|
|
</section>
|
|
|
|
<section>
|
|
<h2>Architecture</h2>
|
|
<h4>Modularity</h4>
|
|
<p>We designed libreant to be:</p>
|
|
<ul>
|
|
<li>Modular</li>
|
|
<li>Easy to read</li>
|
|
<li>Hackable</li>
|
|
</ul>
|
|
<p><small><a href=./index.html#/2/2>Back</a></small></p>
|
|
</section>
|
|
</section>
|
|
|
|
<section>
|
|
<section data-markdown>
|
|
<script type="text/template">
|
|
## The code
|
|
#### Fork me on github
|
|
|
|
Easy as a fork
|
|
|
|
```
|
|
git clone https://github.com/insomnia-lab/libreant
|
|
```
|
|
</script>
|
|
</section>
|
|
|
|
<section data-markdown>
|
|
<script type="text/template">
|
|
## Read the docs!
|
|
|
|
We have been trying also to document appropriately the code!
|
|
|
|
[libreant.rtfd.org](http://libreant.rtfd.org)
|
|
</script>
|
|
</section>
|
|
|
|
<section>
|
|
<h1 style="padding-top: 150px">THANKS</h1>
|
|
</section>
|
|
</section>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<script src="lib/js/head.min.js"></script>
|
|
<script src="js/reveal.min.js"></script>
|
|
|
|
<script>
|
|
|
|
// Full list of configuration options available here:
|
|
// https://github.com/hakimel/reveal.js#configuration
|
|
Reveal.initialize({
|
|
controls: true,
|
|
progress: true,
|
|
history: true,
|
|
|
|
theme: Reveal.getQueryHash().theme, // available themes are in /css/theme
|
|
transition: Reveal.getQueryHash().transition || 'default', // default/cube/page/concave/zoom/linear/none
|
|
|
|
// Optional libraries used to extend on reveal.js
|
|
dependencies: [
|
|
{ src: 'lib/js/classList.js', condition: function() { return !document.body.classList; } },
|
|
{ src: 'plugin/markdown/showdown.js', condition: function() { return !!document.querySelector( '[data-markdown]' ); } },
|
|
{ src: 'plugin/markdown/markdown.js', condition: function() { return !!document.querySelector( '[data-markdown]' ); } },
|
|
{ src: 'plugin/highlight/highlight.js', async: true, callback: function() { hljs.initHighlightingOnLoad(); } },
|
|
{ src: 'plugin/zoom-js/zoom.js', async: true, condition: function() { return !!document.body.classList; } },
|
|
{ src: 'plugin/notes/notes.js', async: true, condition: function() { return !!document.body.classList; } }
|
|
]
|
|
});
|
|
|
|
</script>
|
|
|
|
</body>
|
|
</html>
|