diff --git a/nixos/modules/virtualisation/kubevirt.nix b/nixos/modules/virtualisation/kubevirt.nix index 408822b6af0bd..b67384502989b 100644 --- a/nixos/modules/virtualisation/kubevirt.nix +++ b/nixos/modules/virtualisation/kubevirt.nix @@ -1,4 +1,9 @@ -{ config, lib, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: { imports = [ diff --git a/nixos/modules/virtualisation/vagrant-virtualbox-image.nix b/nixos/modules/virtualisation/vagrant-virtualbox-image.nix index 556228436b992..0d1adc3d7b9a6 100644 --- a/nixos/modules/virtualisation/vagrant-virtualbox-image.nix +++ b/nixos/modules/virtualisation/vagrant-virtualbox-image.nix @@ -29,31 +29,31 @@ mkdir workdir cd workdir - # 1. create that metadata.json file - echo '{"provider":"virtualbox"}' > metadata.json - - # 2. create a default Vagrantfile config - cat <<VAGRANTFILE > Vagrantfile - Vagrant.configure("2") do |config| - config.vm.base_mac = "0800275F0936" - end - VAGRANTFILE - - # 3. add the exported VM files - tar xvf ${config.system.build.virtualBoxOVA}/*.ova - - # 4. move the ovf to the fixed location - mv *.ovf box.ovf - - # 5. generate OVF manifest file - rm *.mf - touch box.mf - for fname in *; do - checksum=$(sha256sum $fname | cut -d' ' -f 1) - echo "SHA256($fname)= $checksum" >> box.mf - done - - # 6. compress everything back together - tar --owner=0 --group=0 --sort=name --numeric-owner -czf $out . - ''; + # 1. create that metadata.json file + echo '{"provider":"virtualbox"}' > metadata.json + + # 2. create a default Vagrantfile config + cat <<VAGRANTFILE > Vagrantfile + Vagrant.configure("2") do |config| + config.vm.base_mac = "0800275F0936" + end + VAGRANTFILE + + # 3. add the exported VM files + tar xvf ${config.system.build.virtualBoxOVA}/*.ova + + # 4. move the ovf to the fixed location + mv *.ovf box.ovf + + # 5. generate OVF manifest file + rm *.mf + touch box.mf + for fname in *; do + checksum=$(sha256sum $fname | cut -d' ' -f 1) + echo "SHA256($fname)= $checksum" >> box.mf + done + + # 6. compress everything back together + tar --owner=0 --group=0 --sort=name --numeric-owner -czf $out . + ''; } diff --git a/nixos/modules/virtualisation/vmware-image.nix b/nixos/modules/virtualisation/vmware-image.nix index 47b7c212bcd17..21aee5f4ed8b6 100644 --- a/nixos/modules/virtualisation/vmware-image.nix +++ b/nixos/modules/virtualisation/vmware-image.nix @@ -1,4 +1,9 @@ -{ config, pkgs, lib, ... }: +{ + config, + pkgs, + lib, + ... +}: let boolToStr = value: if value then "on" else "off"; cfg = config.vmware;