From 531c78ebe02d30ab32ec40ab84004a1bb67fd2d7 Mon Sep 17 00:00:00 2001 From: Noah Masur <7386960+nmasur@users.noreply.github.com> Date: Thu, 5 May 2022 09:21:34 -0400 Subject: [PATCH] set flake for hostname --- Makefile | 2 +- flake.nix | 1 + modules/hardware/networking.nix | 7 ++++--- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 2cfe100..a1b30b6 100644 --- a/Makefile +++ b/Makefile @@ -41,4 +41,4 @@ python: brews nix: git add -A - doas nixos-rebuild build --flake ".#desktop" + doas nixos-rebuild switch --flake . diff --git a/flake.nix b/flake.nix index e0b0686..f696486 100644 --- a/flake.nix +++ b/flake.nix @@ -37,6 +37,7 @@ }; modules = [ home-manager.nixosModules.home-manager + { networking.hostName = "desktop"; } ./hosts/desktop/hardware-configuration.nix ./modules/common.nix ./modules/desktop diff --git a/modules/hardware/networking.nix b/modules/hardware/networking.nix index 705434b..021d02a 100644 --- a/modules/hardware/networking.nix +++ b/modules/hardware/networking.nix @@ -1,7 +1,8 @@ -{ identity, ... }: { +{ ... }: { - networking.hostName = identity.hostname; # Define your hostname. - # networking.wireless.enable = true; # Enables wireless support via wpa_supplicant. + networking.wireless.enable = + true; # Enables wireless support via wpa_supplicant. + networking.wireless.userControlled.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