Hi everyone, anyone aware of a gemini server for android? preferably with builts available as apk.
Aug 03 ยท 2 months ago ยท ๐ jsreed5
7 Comments โ
๐ meidam ยท Aug 03 at 21:06:
Do you mean a client? Or are you intending to serve a gemini capsule from your android phone?
โ๏ธ gim ยท Aug 04 at 15:49:
it's certainly doable, although I'm not quite sure if anyone has tried that. There are various issues with such apps on android.
- the app itself needs to be a "ForegroundService"
- it needs to always show notifications (and obviously needs to have permission to show notification)
more details in android developers portal:
โ https://developer.android.com/develop/background-work/services#Types-of-services
๐พ jecxjo ยท Aug 04 at 19:51:
Additional thoughts...
You'd need to take on a whole different concept of how the certs are handled. Mobile devices are constantly having IP address changes so it would need to generate a new key on IP changed (and hopefully cache them for later use).
Outbound services on mobile is also not usually a great thing. Between cellular service and wifi you're going to be trying to handle multiple hosting scenarios. Add in VPN and you're now up another level.
๐ฒ Half_Elf_Monk ยท Aug 06 at 01:42:
I've thought about this too. My conclusions were: ... if the aim is to use a spare device to serve a capsule over a stable wifi connection, I'm guessing "an old phone" is still a pretty high-friction device. Might be easier/cheaper/better to get a raspberry pi for the same purpose. I love reusing spare devices, but maybe trading for a pi / pico / etc is a more efficient net use of resources.
๐ jsreed5 ยท Aug 06 at 13:55:
If you want to host Gemini from an old phone on WiFi (running at least Android Lollipop), your best bet is probably to install Termux, run a server package from there, and remove/disable as many other apps as you can to minimize processor and memory load. 1965 is an unprivileged port, so Android will allow it to be opened. Unless you only plan to use the server locally, you will likely also need a dynamic DNS service to make it reachable, or use an alternate routing system like Yggdrasil and ALFIS. Be aware that keeping your phone on a charger all the time will damage the battery; if possible, mod your phone to remove it, or have spares on hand and watch closely for swelling.
Hosting Gemini from a daily driver phone is much harder. It's very likely mobile networks will block port 1965, so hosting will probably be impossible without Yggdrasil or some other tunnel/VPN interface. Even then, there's no guarantee it'll work.
๐ Tomi [OP] ยท Aug 06 at 21:32:
@meidam the idea was to serve a capsule as I have a spare smartphone which is not usable as a phone due to touchscreen not being reliable.
Thanks for the suggestions everyone, yes I had thought about termux but was wondering if something native already exists. I also have some spare raspberry pi and I have other plans for them but I liked the idea of having the smartphone battery working as a mini ups. I was thinking of conmecting it to a solar charger so that the battery would slowly charge during the day and would discharge during the night.
๐ฒ Half_Elf_Monk ยท Aug 08 at 19:07:
@Tomi - check out LowTech Magazine. It does something like that as a solar-powered website.
โ https://solar.lowtechmagazine.com/
If you end up doing this, let us know how it works!
Source