add vm named hugo
Signed-off-by: Xe <me@christine.website>
This commit is contained in:
parent
f21903d83d
commit
8ac09a92e9
|
@ -0,0 +1,5 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
nix run github:serokell/deploy-rs
|
23
flake.nix
23
flake.nix
|
@ -20,7 +20,8 @@
|
||||||
home-manager.nixosModules.home-manager
|
home-manager.nixosModules.home-manager
|
||||||
({ config, ... }: {
|
({ config, ... }: {
|
||||||
system.configurationRevision = self.sourceInfo.rev;
|
system.configurationRevision = self.sourceInfo.rev;
|
||||||
services.getty.greetingLine = ''<<< Welcome to NixOS ${config.system.nixos.label} @ ${self.sourceInfo.rev} - \l >>>'';
|
services.getty.greetingLine =
|
||||||
|
"<<< Welcome to NixOS ${config.system.nixos.label} @ ${self.sourceInfo.rev} - \\l >>>";
|
||||||
})
|
})
|
||||||
] ++ extraModules;
|
] ++ extraModules;
|
||||||
};
|
};
|
||||||
|
@ -32,7 +33,13 @@
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
nixosConfigurations.logos = mkSystem [ ./hosts/logos ./hardware/alrest ];
|
nixosConfigurations = {
|
||||||
|
logos = mkSystem [ ./hosts/logos ./hardware/alrest ];
|
||||||
|
|
||||||
|
# vms
|
||||||
|
## logos
|
||||||
|
hugo = mkSystem [ ./hosts/vm/hugo ./hardware/libvirt-generic ];
|
||||||
|
};
|
||||||
|
|
||||||
deploy.nodes.logos = {
|
deploy.nodes.logos = {
|
||||||
hostname = "192.168.2.35";
|
hostname = "192.168.2.35";
|
||||||
|
@ -46,6 +53,18 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
deploy.nodes.hugo = {
|
||||||
|
hostname = "10.77.129.6";
|
||||||
|
sshUser = "root";
|
||||||
|
fastConnection = true;
|
||||||
|
|
||||||
|
profiles.system = {
|
||||||
|
user = "root";
|
||||||
|
path = deploy-rs.lib.x86_64-linux.activate.nixos
|
||||||
|
self.nixosConfigurations.hugo;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
# This is highly advised, and will prevent many possible mistakes
|
# This is highly advised, and will prevent many possible mistakes
|
||||||
checks = builtins.mapAttrs
|
checks = builtins.mapAttrs
|
||||||
(system: deployLib: deployLib.deployChecks self.deploy) deploy-rs.lib;
|
(system: deployLib: deployLib.deployChecks self.deploy) deploy-rs.lib;
|
||||||
|
|
|
@ -0,0 +1,25 @@
|
||||||
|
{ config, pkgs, modulesPath, ... }:
|
||||||
|
{
|
||||||
|
imports = [ (modulesPath + "/profiles/qemu-guest.nix") ../../common ];
|
||||||
|
|
||||||
|
services.openssh.enable = true;
|
||||||
|
|
||||||
|
boot.initrd.availableKernelModules =
|
||||||
|
[ "ata_piix" "uhci_hcd" "virtio_pci" "sr_mod" "virtio_blk" ];
|
||||||
|
boot.initrd.kernelModules = [ ];
|
||||||
|
boot.kernelModules = [ ];
|
||||||
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
|
boot.loader.grub.enable = true;
|
||||||
|
boot.loader.grub.version = 2;
|
||||||
|
boot.loader.grub.device = "/dev/vda";
|
||||||
|
|
||||||
|
nixpkgs.config.allowUnfree = true;
|
||||||
|
|
||||||
|
fileSystems."/" = {
|
||||||
|
device = "/dev/vda1";
|
||||||
|
fsType = "ext4";
|
||||||
|
};
|
||||||
|
|
||||||
|
services.qemuGuest.enable = true;
|
||||||
|
}
|
|
@ -0,0 +1,3 @@
|
||||||
|
{ ... }: {
|
||||||
|
networking.hostName = "hugo";
|
||||||
|
}
|
Loading…
Reference in New Issue