diff --git a/README.md b/README.md index c742662..677356f 100644 --- a/README.md +++ b/README.md @@ -14,15 +14,22 @@ * [x] Split stuff into multiple files * [x] Make a flake * [x] merge hosted docs into a single subdomain +* [x] Setup some remote-development and deploy flow * [ ] autogenerate ssh keys * [ ] switch to systemd networkd * [ ] pre-commit hook with 'nix eval ...outPath' * [ ] use `nom` when deploying * [ ] figure out how to reuse system flake lock while deplying, leave the night job to upgrade -* [ ] Setup some remote-development and deploy flow * [ ] users/pbsds: Support multiple profiles, like headless, nixpkgs-dev, various desktops, hpc, pvv, etc + * [ ] gnome: + * [ ] lxterminal + * [ ] themes + * [ ] shortcuts + * [ ] pavucontrol + * [ ] * [ ] nixos-generate-config instructions for new hosts * [ ] zfs, declarative pools? +* [ ] some tunneling for NFS hosts * [ ] secrets - nix-sops ? * flexget * transmission diff --git a/flake.nix b/flake.nix index 2e959a5..9b5d341 100644 --- a/flake.nix +++ b/flake.nix @@ -35,6 +35,7 @@ forAllSystems = f: nixpkgs.lib.genAttrs systems (system: f system); overlays = nixlib.mapAttrsToList (name: val: val) self.overlays; + # TODO: move unstable and nur here? tmpConfig = { disabledModules = [ "services/misc/polaris.nix" ]; imports = [ "${inputs.pr-polaris14}/nixos/modules/services/misc/polaris.nix" ]; diff --git a/hardware/rocm.nix b/hardware/rocm.nix new file mode 100644 index 0000000..afe190a --- /dev/null +++ b/hardware/rocm.nix @@ -0,0 +1,12 @@ +{ pkgs, ... }: +{ + services.xserver.videoDrivers = [ "amdgpu" ]; # for some reason nixos-hardware uses "modesetting" + # assumes common-gpu-amd from nixos-hardware is also added + nixpkgs.config.rocmSupport = true; + systemd.tmpfiles.rules = [ + "L+ /opt/rocm/hip - - - - ${pkgs.hip}" + ]; + environment.systemPackages = with pkgs; [ + nvtop + ]; +} diff --git a/hosts/nord/default.nix b/hosts/nord/default.nix index 033902b..cb114f2 100644 --- a/hosts/nord/default.nix +++ b/hosts/nord/default.nix @@ -11,8 +11,15 @@ ../../users # home-manager ../../users/pbsds + ../../hardware/rocm.nix ../../hardware/opengl-intel.nix + + ../../profiles/graphical/gnome # with gdm + ../../profiles/graphical/pipewire + + ../../profiles/nfs/reidun.nix + /** / ../../profiles/web ../../profiles/web/index @@ -179,25 +186,6 @@ dejavu_fonts ]; - # GNOME - services.xserver.enable = true; - services.xserver.displayManager.gdm.enable = true; - services.xserver.desktopManager.gnome.enable = true; - #services.printing.enable = true; # CUPS - - # Enable sound with pipewire. - sound.enable = true; - hardware.pulseaudio.enable = false; - security.rtkit.enable = true; - services.pipewire.enable = true; - services.pipewire.alsa.enable = true; - services.pipewire.alsa.support32Bit = true; - #services.pipewire.jack.enable = true; - services.pipewire.pulse.enable = true; - # use the example session manager (no others are packaged yet so this is enabled by default, - # no need to redefine it in your config for now) - #services.pipewire.media-session.enable = true; - # Enable touchpad support (enabled default in most desktopManager). # services.xserver.libinput.enable = true; diff --git a/profiles/graphical/gnome/default.nix b/profiles/graphical/gnome/default.nix new file mode 100644 index 0000000..8379d16 --- /dev/null +++ b/profiles/graphical/gnome/default.nix @@ -0,0 +1,30 @@ +{ + services.xserver.enable = true; + services.xserver.displayManager.gdm.enable = true; + services.xserver.desktopManager.gnome.enable = true; + #services.printing.enable = true; # CUPS + + services.udev.packages = with pkgs; [ gnome.gnome-settings-daemon ]; + + environment.systemPackages = with pkgs; [ + lxterminal + gnomeExtensions.appindicator + ]; + + environment.gnome.excludePackages = (with pkgs; [ + #gnome-photos + gnome-tour + ]) ++ (with pkgs.gnome; [ + #cheese # webcam tool + gnome-music + gnome-terminal + gedit # text editor + #epiphany # web browser + geary # email reader + totem # video player + tali # poker game + iagno # go game + hitori # sudoku game + atomix # puzzle game + ]); +} diff --git a/profiles/graphical/pipewire/default.nix b/profiles/graphical/pipewire/default.nix new file mode 100644 index 0000000..ab9d080 --- /dev/null +++ b/profiles/graphical/pipewire/default.nix @@ -0,0 +1,13 @@ +{ + sound.enable = true; + hardware.pulseaudio.enable = false; + security.rtkit.enable = true; + services.pipewire.enable = true; + services.pipewire.alsa.enable = true; + services.pipewire.alsa.support32Bit = true; + #services.pipewire.jack.enable = true; + services.pipewire.pulse.enable = true; + # use the example session manager (no others are packaged yet so this is enabled by default, + # no need to redefine it in your config for now) + #services.pipewire.media-session.enable = true; +} diff --git a/users/default.nix b/users/default.nix index 1143242..ee83f7b 100644 --- a/users/default.nix +++ b/users/default.nix @@ -3,7 +3,7 @@ #imports = [ ]; imports = [ inputs.home-manager.nixosModule ]; home-manager.useGlobalPkgs = true; # go brrr - #home-manager.useUserPackages = true # needed if VM + #home-manager.useUserPackages = true # needed if VM, will also go a bit more brrr # When adding a new user accounts: Don't forget to set a password with ‘passwd’! }