From 3b0daa1a28a94725122ffcd0f39b452e084c351e Mon Sep 17 00:00:00 2001 From: Michał Pałka Date: Thu, 4 May 2017 08:31:40 +0000 Subject: xen service: Add the possibility to override configuration of xendomains Add the option virtualisation.xen.domain.extraConfig, which allows overriding options passed to xendomains. --- nixos/modules/virtualisation/xen-dom0.nix | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) (limited to 'nixos') diff --git a/nixos/modules/virtualisation/xen-dom0.nix b/nixos/modules/virtualisation/xen-dom0.nix index 1f5b6bd1d80..6e1cb08485c 100644 --- a/nixos/modules/virtualisation/xen-dom0.nix +++ b/nixos/modules/virtualisation/xen-dom0.nix @@ -111,6 +111,19 @@ in ''; }; + virtualisation.xen.domains = { + extraConfig = mkOption { + type = types.string; + default = ""; + description = + '' + Options defined here will override the defaults for xendomains. + The default options can be seen in the file included from + /etc/default/xendomains. + ''; + }; + }; + virtualisation.xen.trace = mkOption { default = false; @@ -216,7 +229,11 @@ in { source = "${cfg.package}/etc/xen/scripts"; target = "xen/scripts"; } - { source = "${cfg.package}/etc/default/xendomains"; + { text = '' + source ${cfg.package}/etc/default/xendomains + + ${cfg.domains.extraConfig} + ''; target = "default/xendomains"; } ]; -- cgit 1.4.1