Podginator / KoboOmnivoreConverter

A Proxy to enable the Kobo Clara to use Omnivore over Pocket for it's articles.
64 stars 9 forks source link

Hosting on vercel #5

Open tent4kel opened 9 months ago

tent4kel commented 9 months ago

Is there a technical reason why this would not work on vercel? I understood that they offer server less functions within their free tier:

https://vercel.com/guides/using-express-with-vercel

Podginator commented 9 months ago

Yes, and no. So basically at the moment the way that it works is by changing the binary for Kobos main software. So in order to limit this we can only change it to the same, or less bytes.

I was looking into how to do this in another way, but I haven't had the time. One idea was to just catch the URL when it is being called by the kobo and change it. This would allow you to do that, but I haven't really got around to it yet.

If you host it, and you can get the name down to a certain size it should work, but you'd have to do quite a lot of fiddling with the internals of the kobo.

tent4kel commented 9 months ago

Ah interesting! So now I understand: You patch libnickel to point to fckpocket.com (same length as the getpocket.com). Then change hardcode the DNS with hosts to point somewhere custom. Only with the limitation that etc/hosts takes only IP.

So either a server with a fixed IP could work, or a url with the same bit-length pointing to a service like vercel.

Is that right?

Podginator commented 8 months ago

Yes, that's exactly right. I just use my raspberry pi because I didn't need to sync outside of the house anyway

Podginator commented 7 months ago

Hey! It is now possible to host this on Vercel. I've updated the way the redirect happens, now it doesn't have to have the same bit length. You can update it in the following file: https://github.com/Podginator/KoboOmnivoreConverter/blob/main/hook/pocket.cc#L38

Then follow the instructions here: https://github.com/Podginator/KoboOmnivoreConverter/blob/main/hook/README.md

to get it up and running.

tent4kel commented 7 months ago

Great! Can't wait to try it!