diff --git a/features/protonvpn.nix b/features/protonvpn.nix new file mode 100644 index 0000000..08f325e --- /dev/null +++ b/features/protonvpn.nix @@ -0,0 +1,19 @@ +{ pkgs, ... }: + +{ + environment.systemPackages = with pkgs; [ + protonvpn-cli + ]; + + security.sudo.extraRules = [ + { + users = [ "srid" ]; + commands = [ + { + command = "${pkgs.protonvpn-cli}/bin/protonvpn"; + options = [ "NOPASSWD" ]; + } + ]; + } + ]; +} diff --git a/features/virtualization.nix b/features/virtualization.nix index 1482ebf..25402a6 100644 --- a/features/virtualization.nix +++ b/features/virtualization.nix @@ -1,6 +1,9 @@ { pkgs, ... }: { - virtualisation.lxd.enable = true; + # virtualisation.lxd.enable = true; + + virtualisation.docker.enable = true; + users.users.srid = { - extraGroups = [ "lxd" ]; + extraGroups = [ "lxd" "docker" ]; }; } diff --git a/flake.nix b/flake.nix index 09869fb..c3d195c 100644 --- a/flake.nix +++ b/flake.nix @@ -29,6 +29,7 @@ # Features common to all of my machines ./features/passwordstore.nix ./features/syncthing.nix + ./features/protonvpn.nix ./features/email ./features/emacs.nix ./features/monitor-brightness.nix @@ -52,7 +53,7 @@ [ inputs.nixos-hardware.nixosModules.lenovo-thinkpad-p53 ./features/desktopish - # ./features/virtualization.nix + ./features/virtualization.nix ./features/postgrest.nix ]; nixosConfigurations.x1c7 = mkHomeMachine