Hey, nice job Ricardo! This looks awesome! On Wed, Sep 13, 2023 at 11:29 AM Katherine Cox-Buday <cox.katherin...@gmail.com> wrote: > > On 9/13/23 3:06 AM, Ricardo Wurmus wrote: > > Hi there, > > > > you know the Shepherd: it is an elegant service manager looking after a > > herd of daemons. Since it can be extended with Guile, I decided to do > > just that to add an extra skill to the Shepherd, turning it into the > > Swineherd. > > > > The Swineherd is a manager of Guix System containers. It is implemented > > as a Shepherd service called “swineherd” that lets you manage Guix > > System containers as Shepherd services. These system container services > > implement a few common features to bring up bridge networking, execute > > commands inside the containers, peek at files, and get simple usage > > stats. > > > > Swineherd also provides an optional HTTP API server to launch, manage, > > and destroy containers through an HTTP client. This makes the Swineherd > > useful for building web applications that launch Guix System containers > > on demand. It comes with an Info manual describing the assumptions, the > > required setup, as well as the implemented commands and the HTTP API. > > > > The Swineherd was designed to be used with Shepherd on foreign distros, > > so it does not assume to be running on top of Guix System (for better or > > worse). > > > > You can find the code here: > > > > https://github.com/BIMSBbioinfo/swineherd > > > > Of course the Swineherd is also available as a Guix package called > > “swineherd”. > > > > If this tickles your interests I’d be very happy to hear your comments > > and incorporate patches to extend it beyond my original requirements. > > This is really cool stuff! I'd love to see Guix continue to eat the > dev-ops space, which, in my opinion, loves to stack complexity on top of > complexity.
+1 to that. I did devops professionally for about 6 years and it really is a mess. > Can you share any ways you're currently using this? > > Any plans/interest in hooking it into `guix deploy`? Hey now that's a cool idea! Speaking of devops, I believe with swineherd it is now possible to implement something I've wanted for many years: the Guix equivalent of docker-compose. It would be like an enhanced guix shell that also starts up services needed for development like PostgreSQL or Redis or whatever. - Dave