acouvreur / sablier

Start your containers on demand, shut them down automatically when there's no activity. Docker, Docker Swarm Mode and Kubernetes compatible.
https://acouvreur.github.io/sablier/
GNU Affero General Public License v3.0
1.16k stars 43 forks source link

Unique instances per session #298

Open pl4nty opened 1 month ago

pl4nty commented 1 month ago

I have a few apps that need a unique instance for each session. Would sablier be a good fit for managing these instances? I'm happy to write a PR if so, initially for k8s and the dynamic strategy

acouvreur commented 1 month ago

Hello @pl4nty!

Right now Sablier can only wake up a set of instances for you.

If I'm understanding correctly, you'd like to be able to spin up a docker container session, and each session could be assigned to a unique entity.

So that multiple people accessing may have unique and clean instances, is that right ?

If that's the case, that's not something that is currently supported.


It might be supported in the future, however note that it's a core behavior change: instead of simply shutting down and spinning up, you will now have to deal with creating multiple instances, have a stickiness to it etc.

pl4nty commented 1 month ago

I can start a PR if it's something you'd like to support, but thought I should ask first due to core behaviour changes. I'm hoping the proxies will handle some session affinity, but instance scaling could get tricky. Doesn't seem to be many projects like this either, I could only find one VDI-based approach

acouvreur commented 1 month ago

Sure thing if you want to open a PR, feel free to do it :)

Make sure to start from the beta branch!