mirror of
https://github.com/nix-community/disko
synced 2024-11-14 16:17:06 +00:00
enable network in make-disk-image vm
This commit is contained in:
parent
47eb674434
commit
df20803339
1 changed files with 8 additions and 0 deletions
|
@ -22,6 +22,7 @@ let
|
|||
};
|
||||
dependencies = with pkgs; [
|
||||
bash
|
||||
iproute
|
||||
coreutils
|
||||
gnused
|
||||
parted # for partprobe
|
||||
|
@ -59,6 +60,13 @@ let
|
|||
rootPaths = [ systemToInstall.config.system.build.toplevel ];
|
||||
}}/registration
|
||||
|
||||
# configure user network
|
||||
echo $(${pkgs.iproute}/bin/ip link)
|
||||
${pkgs.iproute}/bin/ip link set dev ens3 up
|
||||
${pkgs.iproute}/bin/ip addr add 10.0.2.15/24 dev ens3
|
||||
${pkgs.iproute}/bin/ip route add default via 10.0.2.2
|
||||
echo 'nameserver 10.0.2.3' > /etc/resolv.conf
|
||||
|
||||
${systemToInstall.config.system.build.diskoScript}
|
||||
'';
|
||||
installer = ''
|
||||
|
|
Loading…
Reference in a new issue