about summary refs log tree commit diff
path: root/nix/configuration.nix
diff options
context:
space:
mode:
authorNguyễn Gia Phong <mcsinyx@disroot.org>2022-05-11 10:40:49 +0900
committerNguyễn Gia Phong <mcsinyx@disroot.org>2022-05-11 10:40:49 +0900
commit5de43bb3740eef3f040da93eea1fe08c9bc26263 (patch)
treebd42cc26c5f8d6444d31b2ee9fb8a54acac59a76 /nix/configuration.nix
parentc1dfc818278a9a85765d95b29a75ac31fb21e40c (diff)
downloaddotfiles-5de43bb3740eef3f040da93eea1fe08c9bc26263.tar.gz
Update lab config
Diffstat (limited to 'nix/configuration.nix')
-rw-r--r--nix/configuration.nix21
1 files changed, 8 insertions, 13 deletions
diff --git a/nix/configuration.nix b/nix/configuration.nix
index 33b4ace..5b1f698 100644
--- a/nix/configuration.nix
+++ b/nix/configuration.nix
@@ -28,28 +28,23 @@
 
   networking = {
     hostName = "nix";
+    hosts = {
+      "0.0.0.0" = [ "9gag.com" "voz.vn" ];
+    };
     nameservers = [ "9.9.9.11" "149.112.112.11" ];
-    extraHosts = ''
-      0.0.0.0 9gag.com
-    '';
     networkmanager.enable = true;
 
-    # The global useDHCP flag is deprecated, therefore explicitly set
-    # to false here.  Per-interface useDHCP will be mandatory in the future,
-    # so this generated config replicates the default behaviour.
-    useDHCP = false;
-    interfaces.enp1s0.useDHCP = true;
-    interfaces.wlp2s0.useDHCP = true;
+    interfaces = {
+      enp1s0.useDHCP = true;
+      wlp2s0.useDHCP = true;
+    };
 
     # Configure network proxy if necessary
     # proxy.default = "http://user:password@proxy:port/";
     # proxy.noProxy = "127.0.0.1,localhost,internal.domain";
 
     # Open ports in the firewall.
-    # firewall.allowedTCPPorts = [ ... ];
-    # firewall.allowedUDPPorts = [ ... ];
-    # Or disable the firewall altogether.
-    # firewall.enable = false;
+    firewall.allowedUDPPorts = [ 4001 ];
   };
 
   # Set your time zone.