summary refs log tree commit diff
path: root/modules
diff options
context:
space:
mode:
authorMel <mel@rnrd.eu>2025-08-28 15:40:14 +0200
committerMel <mel@rnrd.eu>2025-08-28 17:43:32 +0200
commit5a8c692e7efba3801685e14025692c14036f6ba2 (patch)
tree684e777d81fcb9638ae60c28245d2293b5b47bcc /modules
parent3f55de2ca5208b6fe5997766135e00cdff44a4d6 (diff)
downloadminerals-5a8c692e7efba3801685e14025692c14036f6ba2.tar.zst
minerals-5a8c692e7efba3801685e14025692c14036f6ba2.zip
Add dev-server specific common module files
Signed-off-by: Mel <mel@rnrd.eu>
Diffstat (limited to 'modules')
-rw-r--r--modules/development-server.nix100
-rw-r--r--modules/home/development-server.nix33
2 files changed, 133 insertions, 0 deletions
diff --git a/modules/development-server.nix b/modules/development-server.nix
new file mode 100644
index 0000000..4b67ca6
--- /dev/null
+++ b/modules/development-server.nix
@@ -0,0 +1,100 @@
+{
+  me,
+  pkgs,
+  auxiliaryPkgs,
+  unstablePkgs,
+  ...
+}:
+{
+  imports = [
+    ./nix.nix
+    ./user.nix
+    ./locale.nix
+    ./vim.nix
+    ./tmux.nix
+    ./nix-ld.nix
+  ];
+
+  services.envfs.enable = true;
+
+  virtualisation = {
+    libvirtd.enable = true;
+    docker.enable = true;
+  };
+
+  # fish enables this by default,
+  # it makes every nixos rebuild very slow.
+  documentation.man.generateCaches = false;
+  documentation = {
+    info.enable = true;
+    doc.enable = true;
+    dev.enable = true;
+    nixos = {
+      enable = true;
+      includeAllModules = true;
+    };
+  };
+
+  networking.hostName = me.name;
+  services.resolved.enable = true;
+
+  services = {
+    acpid.enable = true;
+    tailscale = {
+      enable = true;
+      useRoutingFeatures = "both";
+      extraUpFlags = [ "--ssh" ];
+    };
+
+    # sometimes needed for gnupg
+    pcscd.enable = true;
+  };
+
+  programs = {
+    fish.enable = true;
+    git.enable = true;
+
+    gnupg.agent = {
+      enable = true;
+      enableSSHSupport = true;
+      pinentryPackage = pkgs.pinentry-curses;
+    };
+  };
+
+  environment.systemPackages = (with pkgs; [
+    file unzip jq dig htop wget screen dive
+    gnupg pinentry-curses age agenix minisign openssl cryptsetup pamtester
+    inetutils pciutils usbutils lshw lsof inxi iw pmutils acpi acpid
+    minicom miniserve netcat-gnu socat tcpdump nmap iftop iperf mtr arp-scan ethtool
+    mitmproxy 
+    yt-dlp ffmpeg_7-full imagemagick
+    senpai
+    qemu_full virtiofsd
+
+    openvpn openvpn3 update-resolv-conf
+
+    ripgrep hyperfine parallel just fzf bat delta eza fd tokei didyoumean
+    universal-ctags compiledb graphviz
+    python3 uv ruff
+    nodejs_22 deno yarn
+    rustc rustup cargo rustfmt
+    go gopls delve go-task gotags golangci-lint
+    meson cmake gnumake ninja gdb gcc clang clang-tools
+    hare haredoc
+    jdk maven gradle
+    nil nixfmt-rfc-style
+    nixpkgs-review nixpkgs-fmt nixpkgs-lint-community
+    postgresql
+    helix alacritty
+
+    ubootTools dtc cloud-utils
+    borgbackup
+
+    man-pages man-pages-posix
+  ]) ++ (with unstablePkgs; [
+    claude-code gemini-cli
+  ]) ++ (with auxiliaryPkgs; [
+  ]);
+
+  environment.etc.openvpn.source = "${pkgs.update-resolv-conf}/libexec/openvpn";
+}
diff --git a/modules/home/development-server.nix b/modules/home/development-server.nix
new file mode 100644
index 0000000..de196ea
--- /dev/null
+++ b/modules/home/development-server.nix
@@ -0,0 +1,33 @@
+{ ... }:
+
+{
+  imports = [
+    ../foundation/home
+
+    ./shell.nix
+  ];
+
+  programs = {
+    git = {
+      enable = true;
+      userName = "Mel";
+      userEmail = "mel@rnrd.eu";
+      signing = {
+        key = "D75A C286 ACA7 00B4 D8EC 377D 2082 F8EC 11CC 009B";
+        signByDefault = true;
+      };
+      ignores = [
+        # ignore most vim swap-files
+        "*~"
+        "[._]*.sw?"
+      ];
+      extraConfig.init.defaultBranch = "main";
+    };
+
+    direnv = {
+      enable = true;
+      nix-direnv.enable = true;
+    };
+  };
+  };
+}