Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Bookshelf – Self-hosted eBook library that runs on object storage (github.com/murerkinn)
162 points by arbayi 23 hours ago | hide | past | favorite | 61 comments
 help



Hi, author of Bookshelf here. It’s great to see the interest in the project, thanks everyone for the feedback and discussion.

Bookshelf is still very early. The main goal has always been to keep the infrastructure as minimal as possible while still giving you a library you fully control. I never intended to turn it into a hosted service that everyone signs up for. I’d rather make it easy for people to host their own library with little to no ongoing cost.

The demo currently runs on Cloudflare Workers and R2, and their free tiers are more than enough for this use case. Setup is also fairly straightforward. I’d like to keep it that way while adding more storage and deployment options so people can choose whatever works best for them.

I’m also planning to improve the reader UI quite a bit, and I’m considering a bundled app for different platforms with things like offline reading.

There’s still a lot to figure out, so I’d be very interested to hear more ideas, feature requests, and use cases people would like to see supported.


S3 compatible servers can keep object level metadata (x-amz-meta-[arbitrary-tag])

Wouldn't that be easier to manage?


If it is helpful to other people here is how I manage my ebook library with flatfiles and heterogeneous devices (Android, macOS, iOS, Kindle, etc)

I have my own eBook library hosted with copyparty. It is a single binary. Runs on plain files. And speaks OPDS for integration with KOreader (Kindle) or Readest (iOS/macOS). https://github.com/9001/copyparty#opds-feeds

It also speaks webdav so I can quickly sync everything via rclone to an SD card on devices like an Android tablet.

I really like the convenience of flat files and multiple protocols.


Copyparty is super cool, it can also be configured to use S3 backend.

How do you manage your reading progress?


Client side end to end encryption is a must have for me when hosting anything nowadays. I am using Cryptomator for this specific reason. It takes away a lot of legal questions because I only need to curate the data to serve my own needs and do not have to curate it for state actors too.

I really wish client side end to end encryption would become more widespread in the developer community. It is not hard to implement anymore and takes away all the headaches of having to comply with certain regulations.

There are so many laws now that regulate copyright and hosting. An accidentally public S3 bucket full of ebooks could technically land you in jail in certain jurisdictions. Automatic shutdown notices. Providers themselves may also automatically scan stored material, and so on. There are so many reasons not to host your media library unencrypted on a third party server.

I recommend using this kind of tool only if you can prove that you are legally allowed to possess every ebook you upload in every jurisdiction you travel to or live in, as well as in the jurisdiction where the server is located.

RIP Aaron Swartz.


> I really wish client side end to end encryption would become more widespread in the developer community.

I think asking every self-hosted app to implement their own encryption is a massive waste of resources. If you need the data encrypted, it should be handled by a dedicated app like Cryptomater or at the OS level.


Hi, author of Bookshelf here. I’ll definitely have a look into client-side end-to-end encryption.

Thanks for bringing this up and for the detailed comment!


Appreciate this suggestion, cryptomator seems super cool and I had not heard of it until reading your comment.

Having built a tool in this space, I enjoy seeing all the Calibre alternatives that have been coming out in the last few years! It's fascinating to see the specific wants that people have.

Bookshelf, for example -- what possesses someone to make an ebook library that _only works on object storage_? Is this a weekend project, answering the question of "what would this look like"? Or was it something the author wanted for a long time?


Author here. It mostly came from a personal need rather than trying to answer "what would this look like on object storage?"

I wanted something with as little infrastructure as possible, ideally no database or additional services to maintain, while still having my library available anywhere. Object storage fit that pretty well, especially with things like R2 where the free tier is already more than enough for a personal ebook library.

That said, I don’t want Bookshelf to be tied to one particular setup forever. The plan is to keep the core idea of minimal infrastructure, while adding more storage/deployment options over time.


I love it! Thanks for sharing. That makes perfect sense - available from anywhere with limited infrastructure.

Looking forward to seeing what comes next for Bookshelf!


Agree so much! It's so interesting all the different use cases and interpretations of those use cases people have.

Like this self-hosted project aims for "simple deployment"/less infra, but I can't imagine how you end up at "use Cloudflare proprietary offerings" and reconcile that with "self hosted".

But if you host the node app yourself and point it at your own seaweedfs/minio/garage that's still more infra than node process+SQLite file.


> Having built a tool in this space, I enjoy seeing all the Calibre alternatives that have been coming out in the last few years!

If there would be just anything actually good. But for some reason they all have just very basic organisation-levels, and barely any support for handling custom data from calibre.

For some reason, streaming ebooks seems to be also not existing. One can either download the whole book, or use some lousy in-browser-reader. So strange how the ebook-world has no decent software for selfhosting.


Kavita has a custom epub library that actually streams the epub pages. The reason why it's non-existent is due to epub being a zip, with a manifest of pages and images. Each page is an html document, so it may have images requested from that manifest.

Most applications just use epub.js which needs the whole book loaded at once.

Edit: Also Kavita does support some calibre tags for metadata and def is much more customizable with a powerful filtering system which you can then bind to your dashboard/side nav.

www.kavitareader.com for those that might be interested (or check the wiki to get a bit more about it).


Of course, now you’ve piqued my interest - what is it that you want from your library management tool?

FWIW the tool I’ve built has no built-in ereader because I use apps like Apple Books or my kobo to read. i don’t need another half-built ereader


For someone looking for a bit more than this, I recently got Bookorbit running and its quite powerful for being so young. https://bookorbit.app/

I’m a huge fan of bookorbit, especially when paired with KOReader. It’s been, bar none, the best reading experience. I love having my highlights saved in software I control and can do whatever I want with. Currently I have multiple e-ink displays around my house that rotate a book quote from my highlights once a day. I love seeing the highlights and I love knowing the whole pipeline is open source.

I had a look at BookOrbit not long ago. Love the fact that it is able to manage all book types (manga, comics, ebooks). Perfect for me and have been struggling to find a good tool that does all of them without being stupid heavy in resources. Once I looked at the repo, source, PRs etc. I noticed how heavy AI use is. This feels purely vibecoded without much for understanding what is actually being delivered. So ended up not using.

Why not use Kavita then? It uses even less resources, it's mature (nearly 5 years old) and supports manga/comics/ebooks with a rich ecosystem of apps (esp with AI now, lots of users are creating mobile apps to connect).

I moved from Grimmory to BookOrbit due to the lower resource usage and absolutely love it.

https://www.reddit.com/r/selfhosted/comments/1tqia6s/i_bench...


Have you done calibre web or others? How does it compare?

I haven't spent much time with calibre-web in a long time but can confidently say BookOrbit blows it out of the water in terms of functionality. I love that I can have one app that handles books and audiobooks. The ecosystem of apps that work with it is growing quick too, Apogee for iOS being a standout for me. They recently added readaloud support (like Amazon Whispersync or Storyteller) natively in the app, which I've never seen done before.

I have no relation to BookOrbit except I'm a very happy user.


The storyteller mobile apps have supported readaloud for years. You can even set different playback speeds for readaloud vs listening, so when you background the app or lock your phone screen, it will switch from the readaloud speed to the listening speed. I typically use like 2.25x for readaloud and 1.5x for listening.

Yes they have, but they didn't have the ability to align a book _on device_ like Apogee does. It just listens for a few seconds of audio to find where you are in the book and then aligns automatically going forward without having to pre-process.

I don't think calibreweb is that old, are you thinking of the calibre webserver?

I'm a fan of audiobookshelf. Don't let the name fool you, it does a lot! I use it for podcasts, audio books, & ebooks. It's great!

I absolutely love audiobookshelf for audiobooks. And I currently use it for my epubs, but it does not handle that particularly well. It doesn't save progress consistently and the UI for page flipping leaves a lot to be desired. Definitely going to check out how OP's library works

You should check out Storyteller. It aligns ebooks with audiobooks to create EPUB3s with media overlays so you can do immersive reading. It also gives you a place to organize your audiobooks and epub library.



Not to hijack but for non object storage use cases I’ve been using Grimmory[1] and like it. Opds, kobo api, kindle email and web reader cover pretty much every use case.

[1] https://github.com/grimmory-tools/grimmory


I use Grimmory, too. It feels a bit "heavy" for me[0] but I like it a lot.

Not necessarily re: resource usage but rather: it does a lot more than what I have any interest in using. I just use it to expose books to my 2 ereaders (via OPDS) and to sync reading progress (via koreader-sync).


Yeah it’s definitely not the lightweight simple solution, its the everything under the sun solution.

This looks really good. Would you mind sharing why you decided not to go for Calibre?

Calibre is a local single user software. There are tools like calibre-web that bring a calibre backend into a multiuser web application but even then you are not supposed to host the calibre database on network storage IIRC.

Grimmory is a web application first which is what I want. Access for my friends and, more importantly to me, an always online library with progress sync across all my reading devices.

Calibre still has some good use cases though like drm stripping and has a better workflow for heavy metadata editing, but my book sources generally come drm free and have good metadata.


Thank you, that’s very helpful. Just added it to my homelab.

No problem!

Might want to look into OPDS support, cf https://opds.io , to make content available to e-readers.

Tangentially related: What are you all using for organizing & managing your physical book library? I've recently come across "Robinson" for doing the library inventory: https://github.com/ryanmccartney/robinson What other good solutions are out there?

I recommend LibraryThing to every book lover I meet.

https://www.librarything.com/


I setup https://grimmory.org/ a week ago. It has a feature where it can sync with kobo by just editing a single config file on the kobo itself and it works great!

BookShelves on macOS/iOS handles the Calibre wireless sync and iCloud reading progress sync if you're in the Apple ecosystem. Has OPDS too.


I've been using Readest (https://web.readest.com/) but I'll definitely be checking this out.

Does anyone have a solution for reading progress sharing across macos library (now using calibre) and moonreader+ on android? What about highlights sharing?

I also want to know this.

About five hundred dependencies (give or take).

npm being npm.


Now if only I had a good self hosted object store option


Missing conditional writes I think

VersityGW is very handy.

Haven't seen this

SeeweedFS?

It's the most promising imo but I had problems using it last time I don't remember. I'll probably try it again and rust fs when it's ready.

Ceph muahaha

Ugh never again

RustFS

Looking forward to trying it when it's GA

RustFS

Does Calibre support S3 these days as a storage backend?

No but you can use s3fs

(I have my Calibre library in iCloud Drive, but if I wasn't inside the Apple Ecosystem I'd use R2)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: