test: init vm config for mininet

This commit is contained in:
catvayor 2025-01-30 13:12:52 +01:00
parent ea68969f2c
commit b08af779d6
Signed by: lbailly
GPG key ID: CE3E645251AC63F3
4 changed files with 25 additions and 2 deletions

1
.gitignore vendored
View file

@ -1,3 +1,4 @@
/target
.direnv
.envrc
nixos.qcow2

View file

@ -1,4 +1,11 @@
{ pkgs ? (import <nixpkgs>) { }, lib ? pkgs.lib }:
let
pkgs = import <nixpkgs> { };
in
pkgs.mkShell {
buildInputs = with pkgs; [ cargo rustc rustfmt ];
buildInputs = with pkgs; [
cargo
rustc
rustfmt
nixos-shell
];
}

1
vm.nix Symbolic link
View file

@ -0,0 +1 @@
vm/vm.nix

14
vm/vm.nix Normal file
View file

@ -0,0 +1,14 @@
{ pkgs, ... }:
{
virtualisation = {
memorySize = 4 * 1024;
cores = 4;
};
programs.mininet.enable = true;
users.users.root.packages = [
pkgs.python3
];
system.stateVersion = "25.05";
}