summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Smith <luke@lukesmith.xyz>2021-08-03 13:06:18 -0400
committerLuke Smith <luke@lukesmith.xyz>2021-08-03 13:06:18 -0400
commit5c12d0ae9a9500a0bf46a3cb9769c77c76dc24bd (patch)
treef2cd5d8a62bd7d5ea3f1f6cbf7d9f71d29328bde
parent5a567307d9865bc5643c56cff052e22bf3e5c131 (diff)
parent4aa7add2b1eaaa4561d5aa43df37bcb991bd73c8 (diff)
Merge branch 'master' of git://github.com/reflex229/landchad
-rw-r--r--calibre.html143
-rw-r--r--index.html8
-rw-r--r--pix/calibre/calibre-1.pngbin0 -> 5823 bytes
-rw-r--r--pix/calibre/calibre-2.pngbin0 -> 15884 bytes
4 files changed, 151 insertions, 0 deletions
diff --git a/calibre.html b/calibre.html
new file mode 100644
index 0000000..0e88410
--- /dev/null
+++ b/calibre.html
@@ -0,0 +1,143 @@
+<!DOCTYPE html>
+<html lang=en>
+ <head>
+ <title>Setting up a Calibre library server &ndash; LandChad.net</title>
+ <meta charset="utf-8"/>
+ <link rel="shortcut icon" href="favicon.ico" type="image/x-icon" />
+ <link rel='stylesheet' type='text/css' href='style.css'>
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+ <link rel='alternate' type='application/rss+xml' title='Land Chad RSS' href='/rss.xml'>
+ </head>
+<body>
+ <header><h1>Setting up a Calibre library server</h1></header>
+ <nav></nav>
+ <main>
+ <p>
+ The Calibre library server is a great way to store your eBooks.
+ It allows you to:
+ <li>Share your books with others.</li>
+ <li>Easily transfer your books between devices and access them from anywhere.</li>
+ </p>
+
+ <h2>Installation</h2>
+
+ <p>
+ Install the Calibre package.
+ </p>
+
+ <pre><code>apt update && apt install calibre
+mkdir /opt/calibre</code></pre>
+
+ <p>
+ Either upload your existing library using <code>rsync</code>. For example to <code>/opt/calibre/</code>.
+ </p>
+
+ <p>
+ On client:
+ </p>
+
+ <pre><code>cd ~/Documents
+rsync -avuP your_library root@example.org:/opt/calibre/</code></pre>
+
+ <p>
+ Or create a library and add a book to it:
+ </p>
+
+<pre><code>cd /opt/calibre
+calibredb add book.epub --with-library your_library</code></pre>
+
+ <aside>
+ <p>
+ For more information about the <code>calibredb</code> command see <code>man calibredb</code>.
+ </p>
+ </aside>
+
+ <p>
+ Add a new user to protect your server:
+ </p>
+
+ <pre><code>calibre-server --manage-users</code></pre>
+
+ <h2>Creating a service</h2>
+
+ <p>
+ Create a new file <code>/etc/systemd/system/calibre-server.service</code> and add the following:
+ </p>
+
+<pre><code>[Unit]
+Description=Calibre library server
+After=network.target
+
+[Service]
+Type=simple
+User=root
+Group=root
+ExecStart=/usr/bin/calibre-server --enable-auth --enable-local-write /opt/calibre/your_library --listen-on 127.0.0.1
+
+[Install]
+WantedBy=multi-user.target
+</code></pre>
+ <aside>
+ <p>
+ You can change the port with the <code>--port</code> prefix. Additional information <code>man calibre-server</code>.
+ </p>
+ </aside>
+
+ <p>
+ Issue <code>systemctl daemon-reload</code> to apply the changes.
+ </p>
+
+ <p>
+ Enable and start the service.
+ </p>
+
+<pre><code>systemctl enable calibre-server
+systemctl start calibre-server</code></pre>
+
+ <h2>A reverse proxy with Nginx</h2>
+
+ <p>
+ Create a new file <code>/etc/nginx/sites-available/calibre</code> and enter the following:
+ </p>
+
+<pre><code>server {
+ listen 80;
+ client_max_body_size 64M; # to upload large books
+ server_name calibre.example.org;
+
+ location / {
+ proxy_pass http://127.0.0.1:8080;
+ }
+}</code></pre>
+
+ <p>
+ Issue a Let's Encrypt certificate. <a href="certbot.html">Detailed instructions and additional information</a>.
+ </p>
+
+ <pre><code>certbot --nginx</code></pre>
+
+ <p>
+ Now just go to calibre.example.org. The server will request an username and a password.
+ </p>
+
+ <a href="pix/calibre-1.png">
+ <img src="pix/calibre/calibre-1.png" alt="calibre">
+ </a>
+
+ <p>
+ After login you will see something like this.
+ </p>
+
+ <a href="pix/calibre-1.png">
+ <img src="pix/calibre/calibre-2.png" alt="calibre">
+ </a>
+
+ <hr>
+
+ <p>
+ Author: rflx -- <a href="https://rflx.xyz">website</a> -- XMR: 48T5XpHTXAZ5Nn8YCypA4aWn1ffQLHJkFGDArXQB6cmrP6cqLY72cu7CR2iq2MmL5Ndu3d47e5MKjGpL4prYgdrTCFAHD9c
+ </p>
+ </main>
+<footer><a href="https://landchad.net">LandChad.net</a></br>Because Everyone should be an Internet LandChad.</br><li><a href="index.html"><img src="pix/chad.gif" alt="chad"></a></li><li><a href="rss.xml"><img src="pix/rss.svg" alt="RSS"></a></li><li><a href="pix/btc.png"><img src="pix/btc.svg" alt="BTC"></a></li><li><a href="pix/xmr.png"><img src="pix/xmr.svg" alt="XMR"></a></li><li><a href="https://github.com/lukesmithxyz/landchad"><img src="pix/git.svg" alt="Github"></a></footer>
+</body>
+</html>
diff --git a/index.html b/index.html
index ca92980..42beeff 100644
--- a/index.html
+++ b/index.html
@@ -70,6 +70,7 @@
<li><a href="gitea.html">Setting up <img src="pix/gitea.svg">Gitea</a></li>
<li><a href="irc.html">Creating your own chat server with <img src="pix/irc.svg">IRC</a></li>
<li><a href="rss-bridge.html">RSS Bridge: Create RSS Feeds for Mainstream Social Media</a></li>
+ <li><a href="calibre.html">Setting up a Calibre library server</a></li>
</ul>
<h3 id=crypto>Accepting Cryptocurrency Tips</h3>
@@ -113,9 +114,16 @@
<li><a href="https://btcpayserver.org/">BTCPay</a></li>
<li>Email webclients</li>
<li>Simple static site generators</li>
+<<<<<<< HEAD
<li>Calibre (library server)</li>
<li><a href="https://www.ejabberd.im/">XMPP ejabberd</a></li>
<li><a href="https://movim.eu/">Movim for XMPP</a></li>
+=======
+ <li>Nitter</li>
+ <li>PeerTube (like YouTube)</li>
+ <li>XMPP ejabberd</li>
+ <li>Movim for XMPP</li>
+>>>>>>> 4aa7add2b1eaaa4561d5aa43df37bcb991bd73c8
</ul>
diff --git a/pix/calibre/calibre-1.png b/pix/calibre/calibre-1.png
new file mode 100644
index 0000000..cf767e0
--- /dev/null
+++ b/pix/calibre/calibre-1.png
Binary files differ
diff --git a/pix/calibre/calibre-2.png b/pix/calibre/calibre-2.png
new file mode 100644
index 0000000..e0c76ba
--- /dev/null
+++ b/pix/calibre/calibre-2.png
Binary files differ