From 369935f26d337a6bcc0f97414ce3c7d2fc0a222c Mon Sep 17 00:00:00 2001 From: Elias Kohout Date: Mon, 13 Apr 2026 20:39:02 +0200 Subject: [PATCH] add netbird --- hosts/laptop/default.nix | 2 ++ hosts/macvm-nix/default.nix | 2 ++ nixos/default.nix | 1 + nixos/modules/netbird.nix | 15 +++++++++++++++ 4 files changed, 20 insertions(+) create mode 100644 nixos/modules/netbird.nix diff --git a/hosts/laptop/default.nix b/hosts/laptop/default.nix index 5c99a9c..3ccff9b 100644 --- a/hosts/laptop/default.nix +++ b/hosts/laptop/default.nix @@ -54,4 +54,6 @@ custom.development.enable = true; custom.development.languages = [ "rust" "python" "nodejs" ]; + custom.netbird.enable = true; + } diff --git a/hosts/macvm-nix/default.nix b/hosts/macvm-nix/default.nix index 217a06a..8bd905a 100644 --- a/hosts/macvm-nix/default.nix +++ b/hosts/macvm-nix/default.nix @@ -50,6 +50,8 @@ custom.development.enable = true; custom.development.languages = [ "python" "nodejs" "go" ]; + custom.netbird.enable = true; + # ssh services.openssh.enable = true; } diff --git a/nixos/default.nix b/nixos/default.nix index b94699d..ea48eaf 100644 --- a/nixos/default.nix +++ b/nixos/default.nix @@ -6,6 +6,7 @@ ./modules/development.nix ./modules/shell.nix ./modules/yubikey.nix + ./modules/netbird.nix ]; # ============================================ diff --git a/nixos/modules/netbird.nix b/nixos/modules/netbird.nix new file mode 100644 index 0000000..97d2386 --- /dev/null +++ b/nixos/modules/netbird.nix @@ -0,0 +1,15 @@ +{ config, lib, pkgs, ... }: + +{ + options.custom.netbird = { + enable = lib.mkEnableOption "NetBird VPN"; + }; + + config = lib.mkIf config.custom.netbird.enable { + services.netbird.enable = true; + + environment.systemPackages = with pkgs; [ + netbird + ]; + }; +}