From c6560c33277e6f65d987bea6a4d3744bef40de4c Mon Sep 17 00:00:00 2001 From: Gerald Mouse Date: Sat, 23 Mar 2024 13:30:23 +0800 Subject: [PATCH] update and rename van-vc2 to van-sin --- lbhost/conf.www.nix | 2 +- lbhost/ston-atl.nix | 2 +- lbhost/{van-vc2.nix => van-sin.nix} | 19 ++++++++++++------- 3 files changed, 14 insertions(+), 9 deletions(-) rename lbhost/{van-vc2.nix => van-sin.nix} (78%) diff --git a/lbhost/conf.www.nix b/lbhost/conf.www.nix index 452fde0..33ee165 100644 --- a/lbhost/conf.www.nix +++ b/lbhost/conf.www.nix @@ -19,7 +19,7 @@ let hostname = config.networking.hostName; maybe' = maybe ( - hostname == "van-vc2" + hostname == "van-sin" ); www-urls = config.lib.wwwURLs or { }; diff --git a/lbhost/ston-atl.nix b/lbhost/ston-atl.nix index c51432a..4660f76 100644 --- a/lbhost/ston-atl.nix +++ b/lbhost/ston-atl.nix @@ -27,7 +27,7 @@ networking.dhcpcd.enable = false; networking.interfaces.ens3.useDHCP = false; networking.interfaces.ens3.ipv6.addresses = [{ - address = "2001:19f0:5401:280:5400:4ff:fed2:df3e"; + address = "2001:19f0:5401:0280:5400:04ff:fed2:df3e"; prefixLength = 64; }]; } diff --git a/lbhost/van-vc2.nix b/lbhost/van-sin.nix similarity index 78% rename from lbhost/van-vc2.nix rename to lbhost/van-sin.nix index 1830883..4e5a4a4 100644 --- a/lbhost/van-vc2.nix +++ b/lbhost/van-sin.nix @@ -14,20 +14,25 @@ # Define on which hard drive you want to install Grub. boot.loader.grub.device = "/dev/vda"; # or "nodev" for efi only - networking.hostName = "van-vc2"; # Define your hostname. + swapDevices = [{ + device = "/var/lib/swapfile"; + size = 2 * 1024; + }]; + + networking.hostName = "van-sin"; # Define your hostname. # network configuration # dhcpcd is not working well with ipv6, # see https://nixos.wiki/wiki/Networking#Prefix_delegation_with_fixed_DUID networking.dhcpcd.enable = false; networking.interfaces.ens3.useDHCP = false; - networking.interfaces.ens3.ipv4.addresses = [{ - address = "207.148.67.66"; - prefixLength = 23; - }]; - networking.defaultGateway = "207.148.66.1"; networking.interfaces.ens3.ipv6.addresses = [{ - address = "2401:c080:1400:484d:5400:04ff:fe56:0956"; + address = "2001:19f0:4400:5172:5400:04ff:fed3:133a"; prefixLength = 64; }]; + networking.interfaces.ens3.ipv4.addresses = [{ + address = "207.148.127.147"; + prefixLength = 23; + }]; + networking.defaultGateway = "207.148.126.1"; } -- 2.11.4.GIT