[Nix-dev] [disnix] Deactivation of services

Kamil Klimkiewicz miglanz at gmail.com
Fri Apr 15 15:53:29 CEST 2011


Hi Sander,

> Ok, so it seems that you create the complete wrapper scripts directly.
> I think when I fix this segfault bug with nested attribute sets,
> allowing them to be used in the build expressions then you probably
> have what you need. Now that I'm thinking about it, it isn't such a
> bad idea having this supported after all :-)

To be precise, I simply have something like this in my service packages:

wrapper = pkgs.writeScript "wrapper" ''
  ...
'';

installPhase = ''
  ensureDir $out/bin
  cp ${wrapper} $out/bin/wrapper
'';

I also simply create separate services for each machine (not manually -
I have a function that takes configuration attribute set as its
parameter) so I practically don't use infrastructure.nix anymore.

But as I said - I'm still wrapping my head around all of this so I
still may not have the best view of things. Simply do what you think is
fine, I need some time to figure everything out.

-- 
Best regards,
Kamil Klimkiewicz



More information about the nix-dev mailing list