From ab0adc9babc45fdff60024639f20cea5f6c41700 Mon Sep 17 00:00:00 2001 From: Jasper Ras Date: Thu, 6 Feb 2025 16:26:22 +0100 Subject: snorlax git stuff --- configuration/snorlax/git.nix | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 configuration/snorlax/git.nix (limited to 'configuration/snorlax/git.nix') diff --git a/configuration/snorlax/git.nix b/configuration/snorlax/git.nix new file mode 100644 index 0000000..e4cee27 --- /dev/null +++ b/configuration/snorlax/git.nix @@ -0,0 +1,26 @@ +{ pkgs, ... }: +{ + networking.firewall.allowedTCPPorts = [ 80 ]; + services.cgit.jap56 = { + enable = true; + group = "git"; + repos = { + nixos.desc = "Contains my NixOS configuration"; + nixos.path = "/var/lib/git/nixos.git"; + }; + }; + users.groups.git = {}; + users.users.git = { + isNormalUser = true; + home = "/var/lib/git"; + shell = pkgs.zsh; + group = "git"; + hashedPassword = "$6$Rc//lmBr5orYHn.0$M9y3Zj4zCe723r8hYGIhPC5kPv5SVGHjF1FsjrT9IIx7trxuNTLtLDQVL9lhmR5/7bFMUFEf0CMx9w7.vgXgY0"; + openssh.authorizedKeys.keyFiles = [ + ../../keys/id_tarrel.pub + ../../keys/id_work.pub + ]; + packages = with pkgs; [ git ]; + }; + services.openssh.settings.AllowUsers = [ "git" ]; +} -- cgit v1.2.3