I've managed to get Docker set up on both a Linux and a Windows host in our organization for internal use.
Now I'd like to set up some "self-cleaning" DevOps worker agents; I've already got a Windows-based image of a DevOps agent prepared on the Windows host which has all we need for our internal build pipelines and which connects to our DevOps when started. Once started it'll keep running pipeline jobs until manually stopped. I can also use the --once
flag when starting the agent itself to have it only process one job before shutting down (there's an issue with the script but it's unrelated to this question).
For reference I'm trying to set up what is generically described in this MS document:
If you want a fresh agent container for every pipeline run, pass the --once flag to the run command. You must also use a container orchestration system, like Kubernetes or Azure Container Instances, to start new copies of the container when the work completes.
My question is which on-prem orchestration systems would be able to handle re-creating the stopped containers, and which of them are "light" in terms of set up? Kubernetes is clearly mentioned, but it feels like a very big and complicated system to set up just for our internal DevOps pipelines (and tools like minikube
and kind
aren't really meant to be used with a Server Core host). Docker Swarm seems much easier to set up but I'm not sure if it can handle the scenario I have in mind.