From 97337d07140cbab503f057f22e99a3e70922262b Mon Sep 17 00:00:00 2001 From: ahuston-0 Date: Thu, 28 Mar 2024 02:39:29 -0400 Subject: [PATCH] Fun artemision changes Signed-off-by: ahuston-0 --- users/alice/home.nix | 19 ++++++++++ users/alice/home/zsh.nix | 2 - .../systems/artemision/configuration.nix | 25 ++++++++++++- users/alice/systems/artemision/desktop.nix | 21 +++++++++++ users/alice/systems/artemision/programs.nix | 1 + users/alice/systems/artemision/secrets.yaml | 7 +++- users/alice/systems/artemision/wifi.nix | 37 +++++++++++++++++++ users/alice/systems/programs.nix | 8 +++- 8 files changed, 114 insertions(+), 6 deletions(-) create mode 100644 users/alice/systems/artemision/wifi.nix diff --git a/users/alice/home.nix b/users/alice/home.nix index a12b48f..2e90fd1 100644 --- a/users/alice/home.nix +++ b/users/alice/home.nix @@ -68,11 +68,25 @@ enableZshIntegration = true; }; + neovim = { + enable = true; + defaultEditor = true; + vimAlias = true; + vimdiffAlias = true; + extraConfig = '' + set bg=dark + set tabstop=2 + set shiftwidth=2 + set expandtab + set smartindent + ''; + }; nix-index = { enable = true; enableZshIntegration = true; }; + tmux.enable = true; topgrade = { enable = true; settings = { @@ -89,5 +103,10 @@ services.ssh-agent.enable = true; + # TODO: add environment bs + home.sessionVariables = { + EDITOR = "nvim"; + }; + home.stateVersion = "23.11"; } diff --git a/users/alice/home/zsh.nix b/users/alice/home/zsh.nix index e79f94c..1a88a02 100644 --- a/users/alice/home/zsh.nix +++ b/users/alice/home/zsh.nix @@ -94,6 +94,4 @@ "hx" = "helix"; }; }; - - # TODO: add environment bs } diff --git a/users/alice/systems/artemision/configuration.nix b/users/alice/systems/artemision/configuration.nix index e86c192..c72f321 100644 --- a/users/alice/systems/artemision/configuration.nix +++ b/users/alice/systems/artemision/configuration.nix @@ -1,10 +1,11 @@ -{ pkgs, ... }: +{ config, pkgs, ... }: { imports = [ ../configuration.nix ../programs.nix ./programs.nix ./desktop.nix + ./wifi.nix ]; time.timeZone = "America/New_York"; @@ -55,5 +56,27 @@ services.fprintd.enable = false; + services.spotifyd = { + enable = true; + settings = { + global = { + username = "snowinginwonderland@gmail.com"; + password_cmd = "cat ${config.sops.secrets."apps/spotify".path}"; + }; + }; + #systemd.services.spotifyd.serviceConfig = systemd.services.spotifyd. + }; + system.stateVersion = "24.05"; + + sops = { + defaultSopsFile = ./secrets.yaml; + secrets = { + "apps/spotify" = { + group = "audio"; + restartUnits = [ "spotifyd.service" ]; + mode = "0440"; + }; + }; + }; } diff --git a/users/alice/systems/artemision/desktop.nix b/users/alice/systems/artemision/desktop.nix index e9d89ec..bae0209 100644 --- a/users/alice/systems/artemision/desktop.nix +++ b/users/alice/systems/artemision/desktop.nix @@ -16,4 +16,25 @@ services.xserver.displayManager.gdm = { enable = true; }; + + services.dbus = { + enable = true; + implementation = "broker"; + }; + + programs.gnupg.agent = { + enable = true; + #pinentryPackage = pkgs.pinentry-rofi; + pinentryPackage = pkgs.pinentry-gnome3; + settings = { + keyserver-options = "auto-key-retrieve"; + auto-key-locate = "hkps://keys.openpgp.org"; + keyserver = "hkps://keys.openpgp.org"; + #keyserver = "hkp://pgp.mit.edu"; + # "na.pool.sks-keyservers.net" + # "ipv4.pool.sks-keyservers.net" + # "p80.pool.sks-keyservers.net" + # ]; + }; + }; } diff --git a/users/alice/systems/artemision/programs.nix b/users/alice/systems/artemision/programs.nix index b96912e..a3df106 100644 --- a/users/alice/systems/artemision/programs.nix +++ b/users/alice/systems/artemision/programs.nix @@ -1,6 +1,7 @@ { pkgs, ... }: { environment.systemPackages = with pkgs; [ + alacritty bat btop croc diff --git a/users/alice/systems/artemision/secrets.yaml b/users/alice/systems/artemision/secrets.yaml index b6e934b..b5ed7e9 100644 --- a/users/alice/systems/artemision/secrets.yaml +++ b/users/alice/systems/artemision/secrets.yaml @@ -8,6 +8,9 @@ example_number: ENC[AES256_GCM,data:g8BIEIcwKRLSbw==,iv:Ay4aiukAvXeDhzlpMPn++zR0 example_booleans: - ENC[AES256_GCM,data:94T9mg==,iv:qKGJke4SGhgN09Yebh5MPrRBDNnguJQ+1dl5XQffGZQ=,tag:0Pa3eujmSxDCnAHKHsx6yQ==,type:bool] - ENC[AES256_GCM,data:gEvfi+Q=,iv:0DrXoZk8OkdUShc7WAKOL8xG26RFZp3M3qYFAb1hDAs=,tag:uemBrdF87nrfLpfnQ8bD8g==,type:bool] +apps: + spotify: ENC[AES256_GCM,data:bp1pdOfS+VGWLtepUjg7KFWw8Fk=,iv:twGO3CjzRxAU81C93mX8qIEZ/FYIQRJnMd2HIuvP9q8=,tag:AJgs0QGFH30E8+ZpaB02TQ==,type:str] +wifi-env: ENC[AES256_GCM,data:rMGgemyp/zspbZGsSUbjTHfjaMtypo50GH1yMxhMOcaGVA==,iv:diJY8gsdLcqpO6kg0QjHEpGI1/k7pxbXg64Y5ZFlK0A=,tag:WdSrvybUkyXNkV4YqggNsQ==,type:str] #ENC[AES256_GCM,data:pC2Kdy7wNc0=,iv:J7Ggfv6K3dCzL42j5MGd+BjQGseoAoYs4k6+yc3FSiA=,tag:9MriduP9SEIi+c1q4tfzlQ==,type:comment] sops: kms: [] @@ -24,8 +27,8 @@ sops: UlhhNzNjTHdVaXlPOFJhc0EyZGh3RDQK1c7nctmrorze4Kr0Grmcmx3N/UYXPwJc FfClOoGxO+4ZDtxG61SDU1UdYae4loQ8roM8jDIPFMfoEum2bT8oXw== -----END AGE ENCRYPTED FILE----- - lastmodified: "2024-03-23T05:46:44Z" - mac: ENC[AES256_GCM,data:/QpK5JuZgnKKHSOTKMRV291UJbPQaNFOx5hheBFx8aVKbS0TGPBMhFp65mw2dOjwT92iyjTxsox/wwev0wcNdNwlvLYTwFdwf4D6FHyLgX/DSkMfqcXbk8HHFlu0LEyd3W6wi2DBsB0KwiVcfsFKoUD4fKbpWnY2EXFOPD6L2Vg=,iv:hPlgFlPqTDXqfcCjRsJuznR+d3PlwT2kJ/TwFe1obfM=,tag:ZkpcEP0u95vvR37GkJGkuQ==,type:str] + lastmodified: "2024-03-28T05:38:52Z" + mac: ENC[AES256_GCM,data:cVxaW4uW9FoOvIDdq4V+ugvm5H/jrplduIuULeFaMbH3EReYNKCq2PRv/BB0i7+eoCSSlzok/Ifb3YuLZCuSust0t6+fD2QP94rJsW/3On/QJI7YniHKlDBihqBmNNaOJz8ybo0rNIOCJfIoN5Pcsrk+S7GiELVEBwPrKcSY/mA=,iv:zE2AhXNZllW5+JwcTe31B84cZrRkNvmctsbV38GDkTk=,tag:jKFyMT/GGIY6boUUy2eQuw==,type:str] pgp: - created_at: "2024-03-23T05:46:35Z" enc: |- diff --git a/users/alice/systems/artemision/wifi.nix b/users/alice/systems/artemision/wifi.nix new file mode 100644 index 0000000..eabe3f0 --- /dev/null +++ b/users/alice/systems/artemision/wifi.nix @@ -0,0 +1,37 @@ +{ config, ... }: +{ + networking.wireless = { + enable = true; + environmentFile = config.sops.secrets."wifi-env".path; + networks = { + "taetaethegae-2.0".psk = "@PASS_taetaethegae_20@"; + }; + }; + + networking.nameservers = [ + "192.168.76.1" + "9.9.9.9" + ]; + + #pinentryPackage = pkgs.pinentry-rofi; + services.resolved = { + enable = true; + dnssec = "true"; + domains = [ "~." ]; + fallbackDns = [ + "1.1.1.1#one.one.one.one" + "1.0.0.1#one.one.one.one" + ]; + dnsovertls = "true"; + }; + + sops = { + defaultSopsFile = ./secrets.yaml; + secrets = { + "wifi-env" = { + owner = "root"; + restartUnits = [ "wpa_supplicant.service" ]; + }; + }; + }; +} diff --git a/users/alice/systems/programs.nix b/users/alice/systems/programs.nix index da67a42..262d6f2 100644 --- a/users/alice/systems/programs.nix +++ b/users/alice/systems/programs.nix @@ -7,28 +7,33 @@ { environment.systemPackages = with pkgs; [ bfg-repo-cleaner + bitwarden-cli candy-icons calibre # calibre dedrm? + cinnamon.nemo discord-canary + eza fanficfare ferium + firefox # gestures replacement gpu-viewer headsetcontrol ipmiview ipscan + kitty masterpdfeditor4 mons # nbt explorer? neovim noisetorch ocrmypdf - pinentry-rofi playonlinux protonmail-bridge protontricks redshift + restic ripgrep rpi-imager rofi-wayland @@ -37,6 +42,7 @@ simple-mtpfs slack snyk + sops spotify spotify-player #swaylock/waylock?