Ho you should look into setting up services with systemd socket. This solved my on demand issues. I made a script to generate the services and sockets automatically. It became really really fast to add a container which start ondemand
Ho you should look into setting up services with systemd socket. This solved my on demand issues. I made a script to generate the services and sockets automatically. It became really really fast to add a container which start ondemand
interdimensionalmeme@lemmy.ml 2 weeks ago
That sounds interesting but my services are mostly in lxc container with dynamically allocated dhcp addresses (I do not wish to maintain a list of static IPs)
And that makes it hard to start them on demand based on incoming connection like you would an httpd process daemon.
My services are only refferred to by hostnames, for instance vaultwarden.lan, but this address does not resolve when the LXC is offline. I guess I could make a static DNS entries in the local dns server and point those to a LXC container orchestrator to stop and start them as they are accessed.
But also, just leaving them all running and ready to answer queries is, so much more convenient if I have the RAM for it.
But I’m sure there are cases where this is the way to go, but I don’t know how to start LXC containers based on sockets without creating static leases and static dns entries, I really like how IP address and DNS names are completely automated on my network !
Diurnambule@jlai.lu 2 weeks ago
Yeah i didn’t try with dynamic adresses. Most of my services are behind a ngnix so I make most socket point to there. I usually go by IP, that an old work habit. Should try some news things. I played with it with DNS but my DNS name were for a whole “PC” (that was a raspberry pi zero) it work well even when i put a nginx on raspberry zero and services on pi4 I still had to have fixed port and resolvable DNS name. I should try to automate DNS, maintaining an nginx up to date is some time a pain.