Compare commits
	
		
			39 Commits
		
	
	
		
			setup-open
			...
			gitea-robo
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| a040ef59a8 | |||
| c8bf3b7c01 | |||
| 069da36895 | |||
| 83f83a91b7 | |||
| 6372a4111e | |||
| bdfb7384c2 | |||
| ace351c0a7 | |||
| cd5c2c0e01 | |||
| 2be9eb16fe | |||
| 64bd33a213 | |||
| 7b5e114944 | |||
| ee8965e18c | |||
| 7125fd2478 | |||
| 0c1762619a | |||
| 84d1ae13c0 | |||
| a3c88b7869 | |||
| 4aa994e7a3 | |||
| fc64139739 | |||
| 75b0c00212 | |||
| 94d73b34ad | |||
| bf50d6478b | |||
| e9dc0d85a0 | |||
| a009b05977 | |||
| 8a8f5659fb | |||
| 13c921c47b | |||
| 819fcef4c2 | |||
| 102a6f9011 | |||
| 86e68f496e | |||
| 394ff94033 | |||
| 6cb7f576a5 | |||
| edb448f7a0 | |||
| 4507ffe2ab | |||
| 882a8f2e88 | |||
| 65da25da7e | |||
| fd81d61a56 | |||
| 2776273a27 | |||
| ebc5b269ef | |||
| 850d0b0ec5 | |||
| 02792fc20e | 
| @@ -10,6 +10,8 @@ | ||||
|  | ||||
|     ./services/acme.nix | ||||
|     ./services/auto-upgrade.nix | ||||
|     ./services/dbus.nix | ||||
|     ./services/fwupd.nix | ||||
|     ./services/irqbalance.nix | ||||
|     ./services/logrotate.nix | ||||
|     ./services/nginx.nix | ||||
| @@ -17,9 +19,12 @@ | ||||
|     ./services/postfix.nix | ||||
|     ./services/smartd.nix | ||||
|     ./services/thermald.nix | ||||
|     ./services/userborn.nix | ||||
|     ./services/userdbd.nix | ||||
|   ]; | ||||
|  | ||||
|   boot.tmp.cleanOnBoot = lib.mkDefault true; | ||||
|   boot.kernelPackages = lib.mkDefault pkgs.linuxPackages_latest; | ||||
|  | ||||
|   time.timeZone = "Europe/Oslo"; | ||||
|  | ||||
| @@ -47,6 +52,8 @@ | ||||
|  | ||||
|   programs.zsh.enable = true; | ||||
|  | ||||
|   security.lockKernelModules = true; | ||||
|   security.protectKernelImage = true; | ||||
|   security.sudo.execWheelOnly = true; | ||||
|   security.sudo.extraConfig = '' | ||||
|     Defaults lecture = never | ||||
|   | ||||
| @@ -5,10 +5,10 @@ | ||||
|       automatic = true; | ||||
|       options = "--delete-older-than 2d"; | ||||
|     }; | ||||
|     optimise.automatic = true; | ||||
|  | ||||
|     settings = { | ||||
|       allow-dirty = true; | ||||
|       auto-optimise-store = true; | ||||
|       builders-use-substitutes = true; | ||||
|       experimental-features = [ "nix-command" "flakes" ]; | ||||
|       log-lines = 50; | ||||
|   | ||||
| @@ -7,7 +7,7 @@ | ||||
|       # --update-input is deprecated since nix 2.22, and removed in lix 2.90 | ||||
|       # https://git.lix.systems/lix-project/lix/issues/400 | ||||
|       "--refresh" | ||||
|       "--override-input" "nixpkgs" "github:nixos/nixpkgs/nixos-24.05-small" | ||||
|       "--override-input" "nixpkgs" "github:nixos/nixpkgs/nixos-24.11-small" | ||||
|       "--override-input" "nixpkgs-unstable" "github:nixos/nixpkgs/nixos-unstable-small" | ||||
|       "--no-write-lock-file" | ||||
|     ]; | ||||
|   | ||||
							
								
								
									
										7
									
								
								base/services/dbus.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										7
									
								
								base/services/dbus.nix
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,7 @@ | ||||
| { ... }: | ||||
| { | ||||
|   services.dbus = { | ||||
|     enable = true; | ||||
|     implementation = "broker"; | ||||
|   }; | ||||
| } | ||||
							
								
								
									
										4
									
								
								base/services/fwupd.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										4
									
								
								base/services/fwupd.nix
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,4 @@ | ||||
| { ... }: | ||||
| { | ||||
|   services.fwupd.enable = true; | ||||
| } | ||||
| @@ -1,42 +1,8 @@ | ||||
| { ... }: | ||||
| { | ||||
|   # source: https://github.com/logrotate/logrotate/blob/main/examples/logrotate.service | ||||
|   systemd.services.logrotate = { | ||||
|     documentation = [ "man:logrotate(8)" "man:logrotate.conf(5)" ]; | ||||
|     unitConfig.RequiresMountsFor = "/var/log"; | ||||
|     serviceConfig = { | ||||
|       Nice = 19; | ||||
|       IOSchedulingClass = "best-effort"; | ||||
|       IOSchedulingPriority = 7; | ||||
|  | ||||
|       ReadWritePaths = [ "/var/log" ]; | ||||
|  | ||||
|       AmbientCapabilities = [ "" ]; | ||||
|       CapabilityBoundingSet = [ "" ]; | ||||
|       DeviceAllow = [ "" ]; | ||||
|       LockPersonality = true; | ||||
|       MemoryDenyWriteExecute = true; | ||||
|       NoNewPrivileges = true; # disable for third party rotate scripts | ||||
|       PrivateDevices = true; | ||||
|       PrivateNetwork = true; # disable for mail delivery | ||||
|       PrivateTmp = true; | ||||
|       ProtectClock = true; | ||||
|       ProtectControlGroups = true; | ||||
|       ProtectHome = true; # disable for userdir logs | ||||
|       ProtectHostname = true; | ||||
|       ProtectKernelLogs = true; | ||||
|       ProtectKernelModules = true; | ||||
|       ProtectKernelTunables = true; | ||||
|       ProtectProc = "invisible"; | ||||
|       ProtectSystem = "full"; | ||||
|       RestrictNamespaces = true; | ||||
|       RestrictRealtime = true; | ||||
|       RestrictSUIDSGID = true; # disable for creating setgid directories | ||||
|       SocketBindDeny = [ "any" ]; | ||||
|       SystemCallArchitectures = "native"; | ||||
|       SystemCallFilter = [ | ||||
|         "@system-service" | ||||
|       ]; | ||||
|     }; | ||||
|     serviceConfig.ReadWritePaths = [ "/var/log" ]; | ||||
|   }; | ||||
| } | ||||
| } | ||||
|   | ||||
| @@ -33,6 +33,10 @@ | ||||
|  | ||||
|   systemd.services.nginx.serviceConfig = lib.mkIf config.services.nginx.enable { | ||||
|     LimitNOFILE = 65536; | ||||
|     # We use jit my dudes | ||||
|     MemoryDenyWriteExecute = lib.mkForce false; | ||||
|     # What the fuck do we use that where the defaults are not enough??? | ||||
|     SystemCallFilter = lib.mkForce null; | ||||
|   }; | ||||
|  | ||||
|   services.nginx.virtualHosts."_" = lib.mkIf config.services.nginx.enable { | ||||
| @@ -41,4 +45,4 @@ | ||||
|     addSSL = true; | ||||
|     extraConfig = "return 444;"; | ||||
|   }; | ||||
| } | ||||
| } | ||||
|   | ||||
							
								
								
									
										4
									
								
								base/services/userborn.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										4
									
								
								base/services/userborn.nix
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,4 @@ | ||||
| { ... }: | ||||
| { | ||||
|   services.userborn.enable = true; | ||||
| } | ||||
							
								
								
									
										4
									
								
								base/services/userdbd.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										4
									
								
								base/services/userdbd.nix
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,4 @@ | ||||
| { ... }: | ||||
| { | ||||
|   services.userdbd.enable = true; | ||||
| } | ||||
							
								
								
									
										120
									
								
								flake.lock
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										120
									
								
								flake.lock
									
									
									
										generated
									
									
									
								
							| @@ -7,11 +7,11 @@ | ||||
|         ] | ||||
|       }, | ||||
|       "locked": { | ||||
|         "lastModified": 1731746438, | ||||
|         "narHash": "sha256-f3SSp1axoOk0NAI7oFdRzbxG2XPBSIXC+/DaAXnvS1A=", | ||||
|         "lastModified": 1741786315, | ||||
|         "narHash": "sha256-VT65AE2syHVj6v/DGB496bqBnu1PXrrzwlw07/Zpllc=", | ||||
|         "owner": "nix-community", | ||||
|         "repo": "disko", | ||||
|         "rev": "cb64993826fa7a477490be6ccb38ba1fa1e18fa8", | ||||
|         "rev": "0d8c6ad4a43906d14abd5c60e0ffe7b587b213de", | ||||
|         "type": "github" | ||||
|       }, | ||||
|       "original": { | ||||
| @@ -20,6 +20,26 @@ | ||||
|         "type": "github" | ||||
|       } | ||||
|     }, | ||||
|     "gergle": { | ||||
|       "inputs": { | ||||
|         "nixpkgs": [ | ||||
|           "nixpkgs" | ||||
|         ] | ||||
|       }, | ||||
|       "locked": { | ||||
|         "lastModified": 1736621371, | ||||
|         "narHash": "sha256-45UIQSQA7R5iU4YWvilo7mQbhY1Liql9bHBvYa3qRI0=", | ||||
|         "ref": "refs/heads/main", | ||||
|         "rev": "3729796c1213fe76e568ac28f1df8de4e596950b", | ||||
|         "revCount": 20, | ||||
|         "type": "git", | ||||
|         "url": "https://git.pvv.ntnu.no/Grzegorz/gergle.git" | ||||
|       }, | ||||
|       "original": { | ||||
|         "type": "git", | ||||
|         "url": "https://git.pvv.ntnu.no/Grzegorz/gergle.git" | ||||
|       } | ||||
|     }, | ||||
|     "greg-ng": { | ||||
|       "inputs": { | ||||
|         "nixpkgs": [ | ||||
| @@ -28,17 +48,17 @@ | ||||
|         "rust-overlay": "rust-overlay" | ||||
|       }, | ||||
|       "locked": { | ||||
|         "lastModified": 1730249639, | ||||
|         "narHash": "sha256-G3URSlqCcb+GIvGyki+HHrDM5ZanX/dP9BtppD/SdfI=", | ||||
|         "lastModified": 1736545379, | ||||
|         "narHash": "sha256-PeTTmGumdOX3rd6OKI7QMCrZovCDkrckZbcHr+znxWA=", | ||||
|         "ref": "refs/heads/main", | ||||
|         "rev": "80e0447bcb79adad4f459ada5610f3eae987b4e3", | ||||
|         "revCount": 34, | ||||
|         "rev": "74f5316121776db2769385927ec0d0c2cc2b23e4", | ||||
|         "revCount": 42, | ||||
|         "type": "git", | ||||
|         "url": "https://git.pvv.ntnu.no/Projects/greg-ng.git" | ||||
|         "url": "https://git.pvv.ntnu.no/Grzegorz/greg-ng.git" | ||||
|       }, | ||||
|       "original": { | ||||
|         "type": "git", | ||||
|         "url": "https://git.pvv.ntnu.no/Projects/greg-ng.git" | ||||
|         "url": "https://git.pvv.ntnu.no/Grzegorz/greg-ng.git" | ||||
|       } | ||||
|     }, | ||||
|     "grzegorz-clients": { | ||||
| @@ -48,17 +68,17 @@ | ||||
|         ] | ||||
|       }, | ||||
|       "locked": { | ||||
|         "lastModified": 1726861934, | ||||
|         "narHash": "sha256-lOzPDwktd+pwszUTbpUdQg6iCzInS11fHLfkjmnvJrM=", | ||||
|         "lastModified": 1736178795, | ||||
|         "narHash": "sha256-mPdi8cgvIDYcgG3FRG7A4BOIMu2Jef96TPMnV00uXlM=", | ||||
|         "ref": "refs/heads/master", | ||||
|         "rev": "546d921ec46735dbf876e36f4af8df1064d09432", | ||||
|         "revCount": 78, | ||||
|         "rev": "fde738910de1fd8293535a6382c2f0c2749dd7c1", | ||||
|         "revCount": 79, | ||||
|         "type": "git", | ||||
|         "url": "https://git.pvv.ntnu.no/Projects/grzegorz-clients.git" | ||||
|         "url": "https://git.pvv.ntnu.no/Grzegorz/grzegorz-clients.git" | ||||
|       }, | ||||
|       "original": { | ||||
|         "type": "git", | ||||
|         "url": "https://git.pvv.ntnu.no/Projects/grzegorz-clients.git" | ||||
|         "url": "https://git.pvv.ntnu.no/Grzegorz/grzegorz-clients.git" | ||||
|       } | ||||
|     }, | ||||
|     "matrix-next": { | ||||
| @@ -68,16 +88,16 @@ | ||||
|         ] | ||||
|       }, | ||||
|       "locked": { | ||||
|         "lastModified": 1727410897, | ||||
|         "narHash": "sha256-tWsyxvf421ieWUJYgjV7m1eTdr2ZkO3vId7vmtvfFpQ=", | ||||
|         "lastModified": 1735857245, | ||||
|         "narHash": "sha256-AKLLPrgXTxgzll3DqVUMa4QlPlRN3QceutgFBmEf8Nk=", | ||||
|         "owner": "dali99", | ||||
|         "repo": "nixos-matrix-modules", | ||||
|         "rev": "ff787d410cba17882cd7b6e2e22cc88d4064193c", | ||||
|         "rev": "da9dc0479ffe22362793c87dc089035facf6ec4d", | ||||
|         "type": "github" | ||||
|       }, | ||||
|       "original": { | ||||
|         "owner": "dali99", | ||||
|         "ref": "v0.6.1", | ||||
|         "ref": "0.7.0", | ||||
|         "repo": "nixos-matrix-modules", | ||||
|         "type": "github" | ||||
|       } | ||||
| @@ -90,11 +110,11 @@ | ||||
|         "rev": "1b4087bd3322a2e2ba84271c8fcc013e6b641a58", | ||||
|         "revCount": 2, | ||||
|         "type": "git", | ||||
|         "url": "https://git.pvv.ntnu.no/Drift/minecraft-data.git" | ||||
|         "url": "https://git.pvv.ntnu.no/Projects/minecraft-kartverket.git" | ||||
|       }, | ||||
|       "original": { | ||||
|         "type": "git", | ||||
|         "url": "https://git.pvv.ntnu.no/Drift/minecraft-data.git" | ||||
|         "url": "https://git.pvv.ntnu.no/Projects/minecraft-kartverket.git" | ||||
|       } | ||||
|     }, | ||||
|     "nix-gitea-themes": { | ||||
| @@ -104,11 +124,11 @@ | ||||
|         ] | ||||
|       }, | ||||
|       "locked": { | ||||
|         "lastModified": 1714416973, | ||||
|         "narHash": "sha256-aZUcvXjdETUC6wVQpWDVjLUzwpDAEca8yR0ITDeK39o=", | ||||
|         "lastModified": 1736531400, | ||||
|         "narHash": "sha256-+X/HVI1AwoPcud28wI35XRrc1kDgkYdDUGABJBAkxDI=", | ||||
|         "ref": "refs/heads/main", | ||||
|         "rev": "2b23c0ba8aae68d3cb6789f0f6e4891cef26cc6d", | ||||
|         "revCount": 6, | ||||
|         "rev": "e4dafd06b3d7e9e6e07617766e9c3743134571b7", | ||||
|         "revCount": 7, | ||||
|         "type": "git", | ||||
|         "url": "https://git.pvv.ntnu.no/oysteikt/nix-gitea-themes.git" | ||||
|       }, | ||||
| @@ -119,43 +139,27 @@ | ||||
|     }, | ||||
|     "nixpkgs": { | ||||
|       "locked": { | ||||
|         "lastModified": 1731663789, | ||||
|         "narHash": "sha256-x07g4NcqGP6mQn6AISXJaks9sQYDjZmTMBlKIvajvyc=", | ||||
|         "lastModified": 1741969460, | ||||
|         "narHash": "sha256-SCNxTTBfMJV7XuTcLUfdAd6cgCGsazzi+DoPrceQrZ0=", | ||||
|         "owner": "NixOS", | ||||
|         "repo": "nixpkgs", | ||||
|         "rev": "035d434d48f4375ac5d3a620954cf5fda7dd7c36", | ||||
|         "rev": "68612419aa6c9fd5b178b81e6fabbdf46d300ea4", | ||||
|         "type": "github" | ||||
|       }, | ||||
|       "original": { | ||||
|         "owner": "NixOS", | ||||
|         "ref": "nixos-24.05-small", | ||||
|         "repo": "nixpkgs", | ||||
|         "type": "github" | ||||
|       } | ||||
|     }, | ||||
|     "nixpkgs-stable": { | ||||
|       "locked": { | ||||
|         "lastModified": 1730602179, | ||||
|         "narHash": "sha256-efgLzQAWSzJuCLiCaQUCDu4NudNlHdg2NzGLX5GYaEY=", | ||||
|         "owner": "NixOS", | ||||
|         "repo": "nixpkgs", | ||||
|         "rev": "3c2f1c4ca372622cb2f9de8016c9a0b1cbd0f37c", | ||||
|         "type": "github" | ||||
|       }, | ||||
|       "original": { | ||||
|         "owner": "NixOS", | ||||
|         "ref": "release-24.05", | ||||
|         "ref": "nixos-24.11-small", | ||||
|         "repo": "nixpkgs", | ||||
|         "type": "github" | ||||
|       } | ||||
|     }, | ||||
|     "nixpkgs-unstable": { | ||||
|       "locked": { | ||||
|         "lastModified": 1731745710, | ||||
|         "narHash": "sha256-SVeiClbgqL071JpAspOu0gCkPSAL51kSIRwo4C/pghA=", | ||||
|         "lastModified": 1741960758, | ||||
|         "narHash": "sha256-pSGMbfkxF7TSeco54W+B1q+g22YCVp1qXHgtrdgtyR4=", | ||||
|         "owner": "NixOS", | ||||
|         "repo": "nixpkgs", | ||||
|         "rev": "dfaa4cb76c2d450d8f396bb6b9f43cede3ade129", | ||||
|         "rev": "845dc1e9cbc2e48640b8968af58b4a19db67aa8f", | ||||
|         "type": "github" | ||||
|       }, | ||||
|       "original": { | ||||
| @@ -192,11 +196,11 @@ | ||||
|         ] | ||||
|       }, | ||||
|       "locked": { | ||||
|         "lastModified": 1725212759, | ||||
|         "narHash": "sha256-yZBsefIarFUEhFRj+rCGMp9Zvag3MCafqV/JfGVRVwc=", | ||||
|         "ref": "refs/heads/master", | ||||
|         "rev": "e7b66b4bc6a89bab74bac45b87e9434f5165355f", | ||||
|         "revCount": 473, | ||||
|         "lastModified": 1741738148, | ||||
|         "narHash": "sha256-cJo6nbcJEOjkazkZ194NDnlsZe0W0wpxeUh2/886uC8=", | ||||
|         "ref": "refs/heads/main", | ||||
|         "rev": "c1802e7cf27c7cf8b4890354c982a4eef5b11593", | ||||
|         "revCount": 486, | ||||
|         "type": "git", | ||||
|         "url": "https://git.pvv.ntnu.no/Projects/nettsiden.git" | ||||
|       }, | ||||
| @@ -208,6 +212,7 @@ | ||||
|     "root": { | ||||
|       "inputs": { | ||||
|         "disko": "disko", | ||||
|         "gergle": "gergle", | ||||
|         "greg-ng": "greg-ng", | ||||
|         "grzegorz-clients": "grzegorz-clients", | ||||
|         "matrix-next": "matrix-next", | ||||
| @@ -245,15 +250,14 @@ | ||||
|       "inputs": { | ||||
|         "nixpkgs": [ | ||||
|           "nixpkgs" | ||||
|         ], | ||||
|         "nixpkgs-stable": "nixpkgs-stable" | ||||
|         ] | ||||
|       }, | ||||
|       "locked": { | ||||
|         "lastModified": 1731748189, | ||||
|         "narHash": "sha256-Zd/Uukvpcu26M6YGhpbsgqm6LUSLz+Q8mDZ5LOEGdiE=", | ||||
|         "lastModified": 1741861888, | ||||
|         "narHash": "sha256-ynOgXAyToeE1UdLNfrUn/hL7MN0OpIS2BtNdLjpjPf0=", | ||||
|         "owner": "Mic92", | ||||
|         "repo": "sops-nix", | ||||
|         "rev": "d2bd7f433b28db6bc7ae03d5eca43564da0af054", | ||||
|         "rev": "d016ce0365b87d848a57c12ffcfdc71da7a2b55f", | ||||
|         "type": "github" | ||||
|       }, | ||||
|       "original": { | ||||
|   | ||||
							
								
								
									
										18
									
								
								flake.nix
									
									
									
									
									
								
							
							
						
						
									
										18
									
								
								flake.nix
									
									
									
									
									
								
							| @@ -2,7 +2,7 @@ | ||||
|   description = "PVV System flake"; | ||||
|  | ||||
|   inputs = { | ||||
|     nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.05-small"; # remember to also update the url in base/services/auto-upgrade.nix | ||||
|     nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.11-small"; # remember to also update the url in base/services/auto-upgrade.nix | ||||
|     nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixos-unstable-small"; | ||||
|  | ||||
|     sops-nix.url = "github:Mic92/sops-nix"; | ||||
| @@ -17,18 +17,20 @@ | ||||
|     pvv-calendar-bot.url = "git+https://git.pvv.ntnu.no/Projects/calendar-bot.git"; | ||||
|     pvv-calendar-bot.inputs.nixpkgs.follows = "nixpkgs"; | ||||
|  | ||||
|     matrix-next.url = "github:dali99/nixos-matrix-modules/v0.6.1"; | ||||
|     matrix-next.url = "github:dali99/nixos-matrix-modules/0.7.0"; | ||||
|     matrix-next.inputs.nixpkgs.follows = "nixpkgs"; | ||||
|  | ||||
|     nix-gitea-themes.url = "git+https://git.pvv.ntnu.no/oysteikt/nix-gitea-themes.git"; | ||||
|     nix-gitea-themes.inputs.nixpkgs.follows = "nixpkgs"; | ||||
|  | ||||
|     greg-ng.url = "git+https://git.pvv.ntnu.no/Projects/greg-ng.git"; | ||||
|     greg-ng.url = "git+https://git.pvv.ntnu.no/Grzegorz/greg-ng.git"; | ||||
|     greg-ng.inputs.nixpkgs.follows = "nixpkgs"; | ||||
|     grzegorz-clients.url = "git+https://git.pvv.ntnu.no/Projects/grzegorz-clients.git"; | ||||
|     gergle.url = "git+https://git.pvv.ntnu.no/Grzegorz/gergle.git"; | ||||
|     gergle.inputs.nixpkgs.follows = "nixpkgs"; | ||||
|     grzegorz-clients.url = "git+https://git.pvv.ntnu.no/Grzegorz/grzegorz-clients.git"; | ||||
|     grzegorz-clients.inputs.nixpkgs.follows = "nixpkgs"; | ||||
|  | ||||
|     minecraft-data.url = "git+https://git.pvv.ntnu.no/Drift/minecraft-data.git"; | ||||
|     minecraft-data.url = "git+https://git.pvv.ntnu.no/Projects/minecraft-kartverket.git"; | ||||
|   }; | ||||
|  | ||||
|   outputs = { self, nixpkgs, nixpkgs-unstable, sops-nix, disko, ... }@inputs: | ||||
| @@ -103,6 +105,7 @@ | ||||
|         modules = [ | ||||
|           inputs.nix-gitea-themes.nixosModules.default | ||||
|           inputs.pvv-nettsiden.nixosModules.default | ||||
|           self.nixosModules.robots-txt | ||||
|         ]; | ||||
|       }; | ||||
|       bob = stableNixosConfig "bob" { | ||||
| @@ -124,19 +127,23 @@ | ||||
|       brzeczyszczykiewicz = stableNixosConfig "brzeczyszczykiewicz" { | ||||
|         modules = [ | ||||
|           inputs.grzegorz-clients.nixosModules.grzegorz-webui | ||||
|           inputs.gergle.nixosModules.default | ||||
|           inputs.greg-ng.nixosModules.default | ||||
|         ]; | ||||
|         overlays = [ | ||||
|           inputs.greg-ng.overlays.default | ||||
|           inputs.gergle.overlays.default | ||||
|         ]; | ||||
|       }; | ||||
|       georg = stableNixosConfig "georg" { | ||||
|         modules = [ | ||||
|           inputs.grzegorz-clients.nixosModules.grzegorz-webui | ||||
|           inputs.gergle.nixosModules.default | ||||
|           inputs.greg-ng.nixosModules.default | ||||
|         ]; | ||||
|         overlays = [ | ||||
|           inputs.greg-ng.overlays.default | ||||
|           inputs.gergle.overlays.default | ||||
|         ]; | ||||
|       }; | ||||
|     }; | ||||
| @@ -144,6 +151,7 @@ | ||||
|     nixosModules = { | ||||
|       snakeoil-certs = ./modules/snakeoil-certs.nix; | ||||
|       snappymail = ./modules/snappymail.nix; | ||||
|       robots-txt = ./modules/robots-txt.nix; | ||||
|     }; | ||||
|  | ||||
|     devShells = forAllSystems (system: { | ||||
|   | ||||
| @@ -6,13 +6,15 @@ in { | ||||
|     ./module.nix # From danio, pending upstreaming | ||||
|   ]; | ||||
|  | ||||
|   disabledModules = [ "services/web-servers/bluemap.nix" ]; | ||||
|   disabledModules = [ "services/web-apps/bluemap.nix" ]; | ||||
|  | ||||
|   sops.secrets."bluemap/ssh-key" = { }; | ||||
|   sops.secrets."bluemap/ssh-known-hosts" = { }; | ||||
|  | ||||
|   services.bluemap = { | ||||
|     enable = true; | ||||
|     package = pkgs.callPackage ./package.nix { }; | ||||
|      | ||||
|     eula = true; | ||||
|     onCalendar = "*-*-* 05:45:00"; # a little over an hour after auto-upgrade | ||||
|  | ||||
|   | ||||
| @@ -26,7 +26,6 @@ let | ||||
|     "webapp.conf" = webappConfig; | ||||
|     "webserver.conf" = webserverConfig; | ||||
|     "packs" = cfg.resourcepacks; | ||||
|     "addons" = cfg.resourcepacks; # TODO | ||||
|   }; | ||||
|  | ||||
|   renderConfigFolder = name: value: pkgs.linkFarm "bluemap-${name}-config" { | ||||
| @@ -38,13 +37,13 @@ let | ||||
|     "webapp.conf" = format.generate "webapp.conf" (cfg.webappSettings // { "update-settings-file" = false; }); | ||||
|     "webserver.conf" = webserverConfig; | ||||
|     "packs" = value.resourcepacks; | ||||
|     "addons" = cfg.resourcepacks; # TODO | ||||
|   }; | ||||
|  | ||||
|   inherit (lib) mkOption; | ||||
| in { | ||||
|   options.services.bluemap = { | ||||
|     enable = lib.mkEnableOption "bluemap"; | ||||
|     package = lib.mkPackageOption pkgs "bluemap" { }; | ||||
|  | ||||
|     eula = mkOption { | ||||
|       type = lib.types.bool; | ||||
| @@ -159,7 +158,7 @@ in { | ||||
|             type = lib.types.path; | ||||
|             default = cfg.resourcepacks; | ||||
|             defaultText = lib.literalExpression "config.services.bluemap.resourcepacks"; | ||||
|             description = "A set of resourcepacks/mods to extract models from loaded in alphabetical order"; | ||||
|             description = "A set of resourcepacks/mods/bluemap-addons to extract models from loaded in alphabetical order"; | ||||
|           }; | ||||
|           settings = mkOption { | ||||
|             type = (lib.types.submodule { | ||||
| @@ -310,9 +309,18 @@ in { | ||||
|         Group = "nginx"; | ||||
|         UMask = "026"; | ||||
|       }; | ||||
|       script = lib.strings.concatStringsSep "\n" ((lib.attrsets.mapAttrsToList | ||||
|         (name: value: "${lib.getExe pkgs.bluemap} -c ${renderConfigFolder name value} -r") | ||||
|         cfg.maps) ++ [ "${lib.getExe pkgs.bluemap} -c ${webappConfigFolder} -gs" ]); | ||||
|       script = '' | ||||
|         # If web folder doesnt exist generate it | ||||
|         test -f "${cfg.webRoot}" || ${lib.getExe cfg.package} -c ${webappConfigFolder} -gs | ||||
|  | ||||
|         # Render each minecraft map | ||||
|         ${lib.strings.concatStringsSep "\n" (lib.attrsets.mapAttrsToList | ||||
|           (name: value: "${lib.getExe cfg.package} -c ${renderConfigFolder name value} -r") | ||||
|           cfg.maps)} | ||||
|  | ||||
|         # Generate updated webapp | ||||
|         ${lib.getExe cfg.package} -c ${webappConfigFolder} -gs | ||||
|       ''; | ||||
|     }; | ||||
|  | ||||
|     systemd.timers."render-bluemap-maps" = lib.mkIf cfg.enableRender { | ||||
|   | ||||
							
								
								
									
										30
									
								
								hosts/bekkalokk/services/bluemap/package.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										30
									
								
								hosts/bekkalokk/services/bluemap/package.nix
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,30 @@ | ||||
| { lib, stdenvNoCC, fetchurl, makeWrapper, jre }: | ||||
|  | ||||
| stdenvNoCC.mkDerivation rec { | ||||
|   pname = "bluemap"; | ||||
|   version = "5.7"; | ||||
|  | ||||
|   src = fetchurl { | ||||
|     url = "https://github.com/BlueMap-Minecraft/BlueMap/releases/download/v${version}/BlueMap-${version}-cli.jar"; | ||||
|     hash = "sha256-8udZYJgrr4bi2mjRYrASd8JwUoUVZW1tZpOLRgafAIw="; | ||||
|   }; | ||||
|  | ||||
|   dontUnpack = true; | ||||
|  | ||||
|   nativeBuildInputs = [ makeWrapper ]; | ||||
|  | ||||
|   installPhase = '' | ||||
|     runHook preInstall | ||||
|     makeWrapper ${jre}/bin/java $out/bin/bluemap --add-flags "-jar $src" | ||||
|     runHook postInstall | ||||
|   ''; | ||||
|  | ||||
|   meta = { | ||||
|     description = "3D minecraft map renderer"; | ||||
|     homepage = "https://bluemap.bluecolored.de/"; | ||||
|     sourceProvenance = with lib.sourceTypes; [ binaryBytecode ]; | ||||
|     license = lib.licenses.mit; | ||||
|     maintainers = with lib.maintainers; [ dandellion h7x4 ]; | ||||
|     mainProgram = "bluemap"; | ||||
|   }; | ||||
| } | ||||
							
								
								
									
										52
									
								
								hosts/bekkalokk/services/gitea/customization.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										52
									
								
								hosts/bekkalokk/services/gitea/customization.nix
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,52 @@ | ||||
| { config, pkgs, lib, fp, ... }: | ||||
| let | ||||
|   cfg = config.services.gitea; | ||||
| in | ||||
| { | ||||
|   services.gitea-themes.monokai = pkgs.gitea-theme-monokai; | ||||
|  | ||||
|   systemd.services.gitea-customization = lib.mkIf cfg.enable { | ||||
|     description = "Install extra customization in gitea's CUSTOM_DIR"; | ||||
|     wantedBy = [ "gitea.service" ]; | ||||
|     requiredBy = [ "gitea.service" ]; | ||||
|  | ||||
|     serviceConfig =  { | ||||
|       Type = "oneshot"; | ||||
|       User = cfg.user; | ||||
|       Group = cfg.group; | ||||
|     }; | ||||
|  | ||||
|     script = let | ||||
|       logo-svg = fp /assets/logo_blue_regular.svg; | ||||
|       logo-png = fp /assets/logo_blue_regular.png; | ||||
|       extraLinks = pkgs.writeText "gitea-extra-links.tmpl" '' | ||||
|         <a class="item" href="https://www.pvv.ntnu.no/">PVV</a> | ||||
|         <a class="item" href="https://wiki.pvv.ntnu.no/">Wiki</a> | ||||
|         <a class="item" href="https://git.pvv.ntnu.no/Drift/-/projects/4">Tokyo Drift Issues</a> | ||||
|       ''; | ||||
|  | ||||
|       project-labels = (pkgs.formats.yaml { }).generate "gitea-project-labels.yaml" { | ||||
|         labels = lib.importJSON ./labels/projects.json; | ||||
|       }; | ||||
|  | ||||
|       customTemplates = pkgs.runCommandLocal "gitea-templates" { | ||||
|         nativeBuildInputs = with pkgs; [ | ||||
|           coreutils | ||||
|           gnused | ||||
|         ]; | ||||
|       } '' | ||||
|         # Bigger icons | ||||
|         install -Dm444 "${cfg.package.src}/templates/repo/icon.tmpl" "$out/repo/icon.tmpl" | ||||
|         sed -i -e 's/24/48/g' "$out/repo/icon.tmpl" | ||||
|       ''; | ||||
|     in '' | ||||
|       install -Dm444 ${logo-svg} ${cfg.customDir}/public/assets/img/logo.svg | ||||
|       install -Dm444 ${logo-png} ${cfg.customDir}/public/assets/img/logo.png | ||||
|       install -Dm444 ${./loading.apng} ${cfg.customDir}/public/assets/img/loading.png | ||||
|       install -Dm444 ${extraLinks} ${cfg.customDir}/templates/custom/extra_links.tmpl | ||||
|       install -Dm444 ${project-labels} ${cfg.customDir}/options/label/project-labels.yaml | ||||
|  | ||||
|       "${lib.getExe pkgs.rsync}" -a "${customTemplates}/" ${cfg.customDir}/templates/ | ||||
|     ''; | ||||
|   }; | ||||
| } | ||||
| @@ -1,10 +1,11 @@ | ||||
| { config, values, fp, pkgs, lib, ... }: | ||||
| { config, values, lib, unstablePkgs, ... }: | ||||
| let | ||||
|   cfg = config.services.gitea; | ||||
|   domain = "git.pvv.ntnu.no"; | ||||
|   sshPort  = 2222; | ||||
| in { | ||||
|   imports = [ | ||||
|     ./customization.nix | ||||
|     ./gpg.nix | ||||
|     ./import-users | ||||
|     ./web-secret-provider | ||||
| @@ -25,6 +26,8 @@ in { | ||||
|     enable = true; | ||||
|     appName = "PVV Git"; | ||||
|  | ||||
|     package = unstablePkgs.gitea; | ||||
|  | ||||
|     database = { | ||||
|       type = "postgres"; | ||||
|       host = "postgres.pvv.ntnu.no"; | ||||
| @@ -130,6 +133,11 @@ in { | ||||
|       }; | ||||
|       "ui.meta".DESCRIPTION = "Bokstavelig talt programvareverkstedet"; | ||||
|     }; | ||||
|  | ||||
|     dump = { | ||||
|       enable = true; | ||||
|       type = "tar.gz"; | ||||
|     }; | ||||
|   }; | ||||
|  | ||||
|   environment.systemPackages = [ cfg.package ]; | ||||
| @@ -155,36 +163,108 @@ in { | ||||
|     }; | ||||
|   }; | ||||
|  | ||||
|   networking.firewall.allowedTCPPorts = [ sshPort ]; | ||||
|   environment.robots-txt."gitea" = { | ||||
|     virtualHost = domain; | ||||
|     rules = [ | ||||
|       { | ||||
|         pre_comment = '' | ||||
|           Gitea internals | ||||
|  | ||||
|   # Extra customization | ||||
|           See these for more information: | ||||
|           - https://gitea.com/robots.txt | ||||
|           - https://codeberg.org/robots.txt | ||||
|         ''; | ||||
|         User-agent = "*"; | ||||
|         Disallow = [ | ||||
|           "/api/*" | ||||
|           "/avatars" | ||||
|           "/*/*/src/commit/*" | ||||
|           "/*/*/commit/*" | ||||
|           "/*/*/*/refs/*" | ||||
|           "/*/*/*/star" | ||||
|           "/*/*/*/watch" | ||||
|           "/*/*/labels" | ||||
|           "/*/*/activity/*" | ||||
|           "/vendor/*" | ||||
|           "/swagger.*.json" | ||||
|           "/repo/create" | ||||
|           "/repo/migrate" | ||||
|           "/org/create" | ||||
|           "/*/*/fork" | ||||
|           "/*/*/watchers" | ||||
|           "/*/*/stargazers" | ||||
|           "/*/*/forks" | ||||
|           "*/.git/" | ||||
|           "/*.git" | ||||
|           "/*.atom" | ||||
|           "/*.rss" | ||||
|         ]; | ||||
|       } | ||||
|       { | ||||
|         pre_comment = "Language Spam"; | ||||
|         Disallow = "/*?lang="; | ||||
|       } | ||||
|       { | ||||
|         pre_comment = '' | ||||
|           AI bots | ||||
|  | ||||
|   services.gitea-themes.monokai = pkgs.gitea-theme-monokai; | ||||
|  | ||||
|   systemd.services.install-gitea-customization = { | ||||
|     description = "Install extra customization in gitea's CUSTOM_DIR"; | ||||
|     wantedBy = [ "gitea.service" ]; | ||||
|     requiredBy = [ "gitea.service" ]; | ||||
|  | ||||
|     serviceConfig =  { | ||||
|       Type = "oneshot"; | ||||
|       User = cfg.user; | ||||
|       Group = cfg.group; | ||||
|     }; | ||||
|  | ||||
|     script = let | ||||
|       logo-svg = fp /assets/logo_blue_regular.svg; | ||||
|       logo-png = fp /assets/logo_blue_regular.png; | ||||
|       extraLinks = pkgs.writeText "gitea-extra-links.tmpl" '' | ||||
|         <a class="item" href="https://www.pvv.ntnu.no/">PVV</a> | ||||
|         <a class="item" href="https://wiki.pvv.ntnu.no/">Wiki</a> | ||||
|         <a class="item" href="https://git.pvv.ntnu.no/Drift/-/projects/4">Tokyo Drift Issues</a> | ||||
|       ''; | ||||
|     in '' | ||||
|       install -Dm444 ${logo-svg} ${cfg.customDir}/public/assets/img/logo.svg | ||||
|       install -Dm444 ${logo-png} ${cfg.customDir}/public/assets/img/logo.png | ||||
|       install -Dm444 ${./loading.apng} ${cfg.customDir}/public/assets/img/loading.png | ||||
|       install -Dm444 ${extraLinks} ${cfg.customDir}/templates/custom/extra_links.tmpl | ||||
|     ''; | ||||
|           Sourced from: | ||||
|           - https://www.vg.no/robots.txt | ||||
|           - https://codeberg.org/robots.txt | ||||
|         ''; | ||||
|         User-agent = [ | ||||
|           "AI2Bot" | ||||
|           "Ai2Bot-Dolma" | ||||
|           "Amazonbot" | ||||
|           "Applebot-Extended" | ||||
|           "Bytespider" | ||||
|           "CCBot" | ||||
|           "ChatGPT-User" | ||||
|           "Claude-Web" | ||||
|           "ClaudeBot" | ||||
|           "Crawlspace" | ||||
|           "Diffbot" | ||||
|           "FacebookBot" | ||||
|           "FriendlyCrawler" | ||||
|           "GPTBot" | ||||
|           "Google-Extended" | ||||
|           "ICC-Crawler" | ||||
|           "ImagesiftBot" | ||||
|           "Kangaroo Bot" | ||||
|           "Meta-ExternalAgent" | ||||
|           "OAI-SearchBot" | ||||
|           "Omgili" | ||||
|           "Omgilibot" | ||||
|           "PanguBot" | ||||
|           "PerplexityBot" | ||||
|           "PetalBot" | ||||
|           "Scrapy" | ||||
|           "SemrushBot-OCOB" | ||||
|           "Sidetrade indexer bot" | ||||
|           "Timpibot" | ||||
|           "VelenPublicWebCrawler" | ||||
|           "Webzio-Extended" | ||||
|           "YouBot" | ||||
|           "anthropic-ai" | ||||
|           "cohere-ai" | ||||
|           "cohere-training-data-crawler" | ||||
|           "facebookexternalhit" | ||||
|           "iaskspider/2.0" | ||||
|           "img2dataset" | ||||
|           "meta-externalagent" | ||||
|           "omgili" | ||||
|           "omgilibot" | ||||
|         ]; | ||||
|         Disallow = "/"; | ||||
|       } | ||||
|       { | ||||
|         Crawl-delay = "2"; | ||||
|       } | ||||
|       { | ||||
|         Sitemap = "https://${domain}/sitemap.xml"; | ||||
|       } | ||||
|     ]; | ||||
|   }; | ||||
|  | ||||
|   networking.firewall.allowedTCPPorts = [ sshPort ]; | ||||
| } | ||||
|   | ||||
| @@ -177,6 +177,7 @@ def ensure_gitea_user_is_part_of_team( | ||||
| # List of teams that all users should be part of by default | ||||
| COMMON_USER_TEAMS = [ | ||||
|     ("Projects", "Members"), | ||||
|     ("Grzegorz", "Members"), | ||||
|     ("Kurs", "Members"), | ||||
| ] | ||||
|  | ||||
|   | ||||
							
								
								
									
										116
									
								
								hosts/bekkalokk/services/gitea/labels/projects.json
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										116
									
								
								hosts/bekkalokk/services/gitea/labels/projects.json
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,116 @@ | ||||
| [ | ||||
|   { | ||||
|     "name": "art", | ||||
|     "exclusive": false, | ||||
|     "color": "#006b75", | ||||
|     "description": "Requires some creativity" | ||||
|   }, | ||||
|   { | ||||
|     "name": "big", | ||||
|     "exclusive": false, | ||||
|     "color": "#754bc4", | ||||
|     "description": "This is gonna take a while" | ||||
|   }, | ||||
|   { | ||||
|     "name": "blocked", | ||||
|     "exclusive": false, | ||||
|     "color": "#850021", | ||||
|     "description": "This issue/PR depends on one or more other issues/PRs" | ||||
|   }, | ||||
|   { | ||||
|     "name": "bug", | ||||
|     "exclusive": false, | ||||
|     "color": "#f05048", | ||||
|     "description": "Something brokey" | ||||
|   }, | ||||
|   { | ||||
|     "name": "ci-cd", | ||||
|     "exclusive": false, | ||||
|     "color": "#d1ff78", | ||||
|     "description": "Continuous integrals and continuous derivation" | ||||
|   }, | ||||
|   { | ||||
|     "name": "crash report", | ||||
|     "exclusive": false, | ||||
|     "color": "#ed1111", | ||||
|     "description": "Report an oopsie" | ||||
|   }, | ||||
|   { | ||||
|     "name": "disputed", | ||||
|     "exclusive": false, | ||||
|     "color": "#5319e7", | ||||
|     "description": "Kranglefanter" | ||||
|   }, | ||||
|   { | ||||
|     "name": "documentation", | ||||
|     "exclusive": false, | ||||
|     "color": "#fbca04", | ||||
|     "description": "Documentation changes required" | ||||
|   }, | ||||
|   { | ||||
|     "name": "duplicate", | ||||
|     "exclusive": false, | ||||
|     "color": "#cccccc", | ||||
|     "description": "This issue or pull request already exists" | ||||
|   }, | ||||
|   { | ||||
|     "name": "feature request", | ||||
|     "exclusive": false, | ||||
|     "color": "#0052cc", | ||||
|     "description": "" | ||||
|   }, | ||||
|   { | ||||
|     "name": "good first issue", | ||||
|     "exclusive": false, | ||||
|     "color": "#009800", | ||||
|     "description": "Get your hands dirty with a new project here" | ||||
|   }, | ||||
|   { | ||||
|     "name": "me gusta", | ||||
|     "exclusive": false, | ||||
|     "color": "#30ff36", | ||||
|     "description": "( ͡° ͜ʖ ͡°)" | ||||
|   }, | ||||
|   { | ||||
|     "name": "packaging", | ||||
|     "exclusive": false, | ||||
|     "color": "#bf642b", | ||||
|     "description": "" | ||||
|   }, | ||||
|   { | ||||
|     "name": "question", | ||||
|     "exclusive": false, | ||||
|     "color": "#cc317c", | ||||
|     "description": "" | ||||
|   }, | ||||
|   { | ||||
|     "name": "security", | ||||
|     "exclusive": false, | ||||
|     "color": "#ed1111", | ||||
|     "description": "Skommel" | ||||
|   }, | ||||
|   { | ||||
|     "name": "techdebt spring cleaning", | ||||
|     "exclusive": false, | ||||
|     "color": "#8c6217", | ||||
|     "description": "The code is smelly 👃" | ||||
|   }, | ||||
|   { | ||||
|     "name": "testing", | ||||
|     "exclusive": false, | ||||
|     "color": "#52b373", | ||||
|     "description": "Poke it and see if it explodes" | ||||
|   }, | ||||
|   { | ||||
|     "name": "ui/ux", | ||||
|     "exclusive": false, | ||||
|     "color": "#f28852", | ||||
|     "description": "User complaints about ergonomics and economics and whatever" | ||||
|   }, | ||||
|   { | ||||
|     "name": "wontfix", | ||||
|     "exclusive": false, | ||||
|     "color": "#ffffff", | ||||
|     "description": "Nei, vil ikke" | ||||
|   } | ||||
| ] | ||||
| @@ -3,6 +3,7 @@ let | ||||
|   organizations = [ | ||||
|     "Drift" | ||||
|     "Projects" | ||||
|     "Grzegorz" | ||||
|     "Kurs" | ||||
|   ]; | ||||
|  | ||||
| @@ -27,6 +28,7 @@ in | ||||
|   users.users."gitea-web" = { | ||||
|     group = "gitea-web"; | ||||
|     isSystemUser = true; | ||||
|     shell = pkgs.bash; | ||||
|   }; | ||||
|  | ||||
|   sops.secrets."gitea/web-secret-provider/token" = { | ||||
| @@ -58,6 +60,7 @@ in | ||||
|           key-dir = "/var/lib/gitea-web/keys/%i"; | ||||
|           authorized-keys-path = "/var/lib/gitea-web/authorized_keys.d/%i"; | ||||
|           rrsync-script = pkgs.writeShellScript "rrsync-chown" '' | ||||
|             mkdir -p "$1" | ||||
|             ${lib.getExe pkgs.rrsync} -wo "$1" | ||||
|             ${pkgs.coreutils}/bin/chown -R gitea-web:gitea-web "$1" | ||||
|           ''; | ||||
|   | ||||
| @@ -34,7 +34,21 @@ def get_org_repo_list(args: argparse.Namespace, token: str): | ||||
|         f"{args.api_url}/orgs/{args.org}/repos", | ||||
|         headers = { 'Authorization': 'token ' + token }, | ||||
|     ) | ||||
|     return [repo["name"] for repo in result.json()] | ||||
|  | ||||
|     results = [repo["name"] for repo in result.json()] | ||||
|     target = int(result.headers['X-Total-Count']) | ||||
|  | ||||
|     i = 2 | ||||
|     while len(results) < target: | ||||
|         result = requests.get( | ||||
|             f"{args.api_url}/orgs/{args.org}/repos", | ||||
|             params = { 'page': i }, | ||||
|             headers = { 'Authorization': 'token ' + token }, | ||||
|         ) | ||||
|         results += [repo["name"] for repo in result.json()] | ||||
|         i += 1 | ||||
|  | ||||
|     return results | ||||
|  | ||||
|  | ||||
| def generate_ssh_key(args: argparse.Namespace, repository: str): | ||||
|   | ||||
| @@ -83,7 +83,6 @@ in { | ||||
|       ProtectKernelLogs = true; | ||||
|       ProtectKernelModules = true; | ||||
|       ProtectKernelTunables = true; | ||||
|       ProtectProc = "invisible"; | ||||
|       RestrictAddressFamilies = [ | ||||
|         "AF_INET" | ||||
|         "AF_INET6" | ||||
| @@ -98,7 +97,6 @@ in { | ||||
|         "@system-service" | ||||
|         "~@privileged" | ||||
|       ]; | ||||
|       UMask = "0007"; | ||||
|     }; | ||||
|   }; | ||||
| } | ||||
|   | ||||
| @@ -21,7 +21,7 @@ in | ||||
|       custom_from | ||||
|     ]); | ||||
|  | ||||
|     dicts = with pkgs.aspellDicts; [ en en-science en-computers nb nn fr de it ]; | ||||
|     dicts = with pkgs.aspellDicts; [ en en-computers nb nn fr de it ]; | ||||
|     maxAttachmentSize = 20; | ||||
|     hostName = "roundcubeplaceholder.example.com"; | ||||
|  | ||||
|   | ||||
| @@ -48,6 +48,9 @@ | ||||
|  | ||||
|   users.users.turnserver.extraGroups = [ "acme" ]; | ||||
|  | ||||
|   # It needs this to be allowed to access the files with the acme group | ||||
|   systemd.services.coturn.serviceConfig.PrivateUsers = lib.mkForce false; | ||||
|  | ||||
|   systemd.services."acme-${config.services.coturn.realm}".serviceConfig = { | ||||
|     AmbientCapabilities = [ "CAP_NET_BIND_SERVICE" ]; | ||||
|   }; | ||||
| @@ -66,7 +69,7 @@ | ||||
|  | ||||
|     listening-ips = [ | ||||
|       values.services.turn.ipv4 | ||||
|       # values.services.turn.ipv6 | ||||
|       values.services.turn.ipv6 | ||||
|     ]; | ||||
|  | ||||
|     tls-listening-port = 443; | ||||
|   | ||||
| @@ -6,10 +6,6 @@ let | ||||
|   webhookListenPort = 8435; | ||||
| in | ||||
| { | ||||
|   imports = [ | ||||
|     ./module.nix | ||||
|   ]; | ||||
|  | ||||
|   sops.secrets."matrix/hookshot/as_token" = { | ||||
|     sopsFile = fp /secrets/bicep/matrix.yaml; | ||||
|     key = "hookshot/as_token"; | ||||
|   | ||||
| @@ -1,127 +0,0 @@ | ||||
| { | ||||
|   config, | ||||
|   pkgs, | ||||
|   lib, | ||||
|   ... | ||||
| }: | ||||
| let | ||||
|   cfg = config.services.matrix-hookshot; | ||||
|   settingsFormat = pkgs.formats.yaml { }; | ||||
|   configFile = settingsFormat.generate "matrix-hookshot-config.yml" cfg.settings; | ||||
| in | ||||
| { | ||||
|   options = { | ||||
|     services.matrix-hookshot = { | ||||
|       enable = lib.mkEnableOption "matrix-hookshot, a bridge between Matrix and project management services"; | ||||
|  | ||||
|       package = lib.mkPackageOption pkgs "matrix-hookshot" { }; | ||||
|  | ||||
|       registrationFile = lib.mkOption { | ||||
|         type = lib.types.path; | ||||
|         description = '' | ||||
|           Appservice registration file. | ||||
|           As it contains secret tokens, you may not want to add this to the publicly readable Nix store. | ||||
|         ''; | ||||
|         example = lib.literalExpression '' | ||||
|           pkgs.writeText "matrix-hookshot-registration" \'\' | ||||
|             id: matrix-hookshot | ||||
|             as_token: aaaaaaaaaa | ||||
|             hs_token: aaaaaaaaaa | ||||
|             namespaces: | ||||
|               rooms: [] | ||||
|               users: | ||||
|                 - regex: "@_webhooks_.*:foobar" | ||||
|                   exclusive: true | ||||
|  | ||||
|             sender_localpart: hookshot | ||||
|             url: "http://localhost:9993" | ||||
|             rate_limited: false | ||||
|             \'\' | ||||
|         ''; | ||||
|       }; | ||||
|  | ||||
|       settings = lib.mkOption { | ||||
|         description = '' | ||||
|           {file}`config.yml` configuration as a Nix attribute set. | ||||
|  | ||||
|           For details please see the [documentation](https://matrix-org.github.io/matrix-hookshot/latest/setup/sample-configuration.html). | ||||
|         ''; | ||||
|         example = { | ||||
|           bridge = { | ||||
|             domain = "example.com"; | ||||
|             url = "http://localhost:8008"; | ||||
|             mediaUrl = "https://example.com"; | ||||
|             port = 9993; | ||||
|             bindAddress = "127.0.0.1"; | ||||
|           }; | ||||
|           listeners = [ | ||||
|             { | ||||
|               port = 9000; | ||||
|               bindAddress = "0.0.0.0"; | ||||
|               resources = [ "webhooks" ]; | ||||
|             } | ||||
|             { | ||||
|               port = 9001; | ||||
|               bindAddress = "localhost"; | ||||
|               resources = [ | ||||
|                 "metrics" | ||||
|                 "provisioning" | ||||
|               ]; | ||||
|             } | ||||
|           ]; | ||||
|         }; | ||||
|         default = { }; | ||||
|         type = lib.types.submodule { | ||||
|           freeformType = settingsFormat.type; | ||||
|           options = { | ||||
|             passFile = lib.mkOption { | ||||
|               type = lib.types.path; | ||||
|               default = "/var/lib/matrix-hookshot/passkey.pem"; | ||||
|               description = '' | ||||
|                 A passkey used to encrypt tokens stored inside the bridge. | ||||
|                 File will be generated if not found. | ||||
|               ''; | ||||
|             }; | ||||
|           }; | ||||
|         }; | ||||
|       }; | ||||
|  | ||||
|       serviceDependencies = lib.mkOption { | ||||
|         type = with lib.types; listOf str; | ||||
|         default = lib.optional config.services.matrix-synapse.enable config.services.matrix-synapse.serviceUnit; | ||||
|         defaultText = lib.literalExpression '' | ||||
|           lib.optional config.services.matrix-synapse.enable config.services.matrix-synapse.serviceUnit | ||||
|         ''; | ||||
|         description = '' | ||||
|           List of Systemd services to require and wait for when starting the application service, | ||||
|           such as the Matrix homeserver if it's running on the same host. | ||||
|         ''; | ||||
|       }; | ||||
|     }; | ||||
|   }; | ||||
|  | ||||
|   config = lib.mkIf cfg.enable { | ||||
|     systemd.services.matrix-hookshot = { | ||||
|       description = "a bridge between Matrix and multiple project management services"; | ||||
|  | ||||
|       wantedBy = [ "multi-user.target" ]; | ||||
|       wants = [ "network-online.target" ] ++ cfg.serviceDependencies; | ||||
|       after = [ "network-online.target" ] ++ cfg.serviceDependencies; | ||||
|  | ||||
|       preStart = '' | ||||
|         if [ ! -f '${cfg.settings.passFile}' ]; then | ||||
|           mkdir -p $(dirname '${cfg.settings.passFile}') | ||||
|           ${pkgs.openssl}/bin/openssl genpkey -out '${cfg.settings.passFile}' -outform PEM -algorithm RSA -pkeyopt rsa_keygen_bits:4096 | ||||
|         fi | ||||
|       ''; | ||||
|  | ||||
|       serviceConfig = { | ||||
|         Type = "simple"; | ||||
|         Restart = "always"; | ||||
|         ExecStart = "${cfg.package}/bin/matrix-hookshot ${configFile} ${cfg.registrationFile}"; | ||||
|       }; | ||||
|     }; | ||||
|   }; | ||||
|  | ||||
|   meta.maintainers = with lib.maintainers; [ flandweber ]; | ||||
| } | ||||
| @@ -15,8 +15,8 @@ let | ||||
|         enable = true; | ||||
|         name = "git-runner-${name}"; url = "https://git.pvv.ntnu.no"; | ||||
|         labels = [ | ||||
|           "debian-latest:docker://node:18-bullseye" | ||||
|           "ubuntu-latest:docker://node:18-bullseye" | ||||
|           "debian-latest:docker://node:current-bookworm" | ||||
|           "ubuntu-latest:docker://node:current-bookworm" | ||||
|         ]; | ||||
|         tokenFile = config.sops.secrets."gitea/runners/${name}".path; | ||||
|       }; | ||||
|   | ||||
| @@ -2,4 +2,10 @@ | ||||
|  | ||||
| { | ||||
|   nix.settings.trusted-users = [ "@nix-builder-users" ]; | ||||
|   nix.daemonCPUSchedPolicy = "batch"; | ||||
|  | ||||
|   boot.binfmt.emulatedSystems = [ | ||||
|     "aarch64-linux" | ||||
|     "armv7l-linux" | ||||
|   ]; | ||||
| } | ||||
|   | ||||
| @@ -2,6 +2,8 @@ | ||||
| let | ||||
|   grg = config.services.greg-ng; | ||||
|   grgw = config.services.grzegorz-webui; | ||||
|  | ||||
|   machine = config.networking.hostName; | ||||
| in { | ||||
|   services.greg-ng = { | ||||
|     enable = true; | ||||
| @@ -16,37 +18,77 @@ in { | ||||
|     listenAddr = "localhost"; | ||||
|     listenPort = 42069; | ||||
|     listenWebsocketPort = 42042; | ||||
|     hostName = "${config.networking.fqdn}"; | ||||
|     apiBase = "http://${grg.settings.host}:${toString grg.settings.port}/api"; | ||||
|     hostName = "${machine}-old.pvv.ntnu.no"; | ||||
|     apiBase = "https://${machine}-backend.pvv.ntnu.no/api"; | ||||
|   }; | ||||
|  | ||||
|   services.gergle = { | ||||
|     enable = true; | ||||
|     virtualHost = config.networking.fqdn; | ||||
|   }; | ||||
|  | ||||
|   services.nginx.enable = true; | ||||
|   services.nginx.virtualHosts."${config.networking.fqdn}" = { | ||||
|     forceSSL = true; | ||||
|     enableACME = true; | ||||
|     kTLS = true; | ||||
|     serverAliases = [ | ||||
|       "${config.networking.hostName}.pvv.org" | ||||
|     ]; | ||||
|     extraConfig = '' | ||||
|       allow 129.241.210.128/25; | ||||
|       allow 2001:700:300:1900::/64; | ||||
|       deny all; | ||||
|     ''; | ||||
|   services.nginx.virtualHosts = { | ||||
|     ${config.networking.fqdn} = { | ||||
|       forceSSL = true; | ||||
|       enableACME = true; | ||||
|       kTLS = true; | ||||
|       serverAliases = [ | ||||
|         "${machine}.pvv.org" | ||||
|       ]; | ||||
|       extraConfig = '' | ||||
|         allow 129.241.210.128/25; | ||||
|         allow 2001:700:300:1900::/64; | ||||
|         deny all; | ||||
|       ''; | ||||
|     }; | ||||
|  | ||||
|     locations."/" = { | ||||
|       proxyPass = "http://${grgw.listenAddr}:${toString grgw.listenPort}"; | ||||
|     "${machine}-backend.pvv.ntnu.no" = { | ||||
|       forceSSL = true; | ||||
|       enableACME = true; | ||||
|       kTLS = true; | ||||
|       serverAliases = [ | ||||
|         "${machine}-backend.pvv.org" | ||||
|       ]; | ||||
|       extraConfig = '' | ||||
|         allow 129.241.210.128/25; | ||||
|         allow 2001:700:300:1900::/64; | ||||
|         deny all; | ||||
|       ''; | ||||
|  | ||||
|       locations."/" = { | ||||
|         proxyPass = "http://${grg.settings.host}:${toString grg.settings.port}"; | ||||
|         proxyWebsockets = true; | ||||
|       }; | ||||
|     }; | ||||
|     # https://github.com/rawpython/remi/issues/216 | ||||
|     locations."/websocket" = { | ||||
|       proxyPass = "http://${grgw.listenAddr}:${toString grgw.listenWebsocketPort}"; | ||||
|       proxyWebsockets = true; | ||||
|     }; | ||||
|     locations."/api" = { | ||||
|       proxyPass = "http://${grg.settings.host}:${toString grg.settings.port}"; | ||||
|     }; | ||||
|     locations."/docs" = { | ||||
|       proxyPass = "http://${grg.settings.host}:${toString grg.settings.port}"; | ||||
|  | ||||
|     "${machine}-old.pvv.ntnu.no" = { | ||||
|       forceSSL = true; | ||||
|       enableACME = true; | ||||
|       kTLS = true; | ||||
|       serverAliases = [ | ||||
|         "${machine}-old.pvv.org" | ||||
|       ]; | ||||
|       extraConfig = '' | ||||
|         allow 129.241.210.128/25; | ||||
|         allow 2001:700:300:1900::/64; | ||||
|         deny all; | ||||
|       ''; | ||||
|  | ||||
|       locations."/" = { | ||||
|         proxyPass = "http://${grgw.listenAddr}:${toString grgw.listenPort}"; | ||||
|       }; | ||||
|       # https://github.com/rawpython/remi/issues/216 | ||||
|       locations."/websocket" = { | ||||
|         proxyPass = "http://${grgw.listenAddr}:${toString grgw.listenWebsocketPort}"; | ||||
|         proxyWebsockets = true; | ||||
|       }; | ||||
|       locations."/api" = { | ||||
|         proxyPass = "http://${grg.settings.host}:${toString grg.settings.port}"; | ||||
|       }; | ||||
|       locations."/docs" = { | ||||
|         proxyPass = "http://${grg.settings.host}:${toString grg.settings.port}"; | ||||
|       }; | ||||
|     }; | ||||
|   }; | ||||
| } | ||||
|   | ||||
							
								
								
									
										116
									
								
								modules/robots-txt.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										116
									
								
								modules/robots-txt.nix
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,116 @@ | ||||
| { config, pkgs, lib, ... }: | ||||
| let | ||||
|   cfg = config.environment.robots-txt; | ||||
|  | ||||
|   robots-txt-format = { | ||||
|     type = let | ||||
|       coercedStrToNonEmptyListOfStr = lib.types.coercedTo lib.types.str lib.singleton (lib.types.nonEmptyListOf lib.types.str); | ||||
|     in lib.types.listOf (lib.types.submodule { | ||||
|       freeformType = lib.types.attrsOf coercedStrToNonEmptyListOfStr; | ||||
|       options = { | ||||
|         pre_comment = lib.mkOption { | ||||
|           description = "Comment to add before the rule"; | ||||
|           type = lib.types.lines; | ||||
|           default = ""; | ||||
|         }; | ||||
|         post_comment = lib.mkOption { | ||||
|           description = "Comment to add after the rule"; | ||||
|           type = lib.types.lines; | ||||
|           default = ""; | ||||
|         }; | ||||
|       }; | ||||
|     }); | ||||
|  | ||||
|     generate = name: value: let | ||||
|       makeComment = comment: lib.pipe comment [ | ||||
|         (lib.splitString "\n") | ||||
|         (lib.map (line: if line == "" then "#" else "# ${line}")) | ||||
|         (lib.concatStringsSep "\n") | ||||
|       ]; | ||||
|  | ||||
|       ruleToString = rule: let | ||||
|         user_agent = rule.User-agent or []; | ||||
|         pre_comment = rule.pre_comment; | ||||
|         post_comment = rule.post_comment; | ||||
|         rest = builtins.removeAttrs rule [ "User-agent" "pre_comment" "post_comment" ]; | ||||
|       in lib.concatStringsSep "\n" (lib.filter (x: x != null) [ | ||||
|         (if (pre_comment != "") then makeComment pre_comment else null) | ||||
|         (let | ||||
|           user-agents = lib.concatMapStringsSep "\n" (value: "User-agent: ${value}") user_agent; | ||||
|         in | ||||
|           if user_agent == [] then null else user-agents | ||||
|         ) | ||||
|         (lib.pipe rest [ | ||||
|           (lib.mapAttrsToList (ruleName: map (value: "${ruleName}: ${value}"))) | ||||
|           lib.concatLists | ||||
|           (lib.concatStringsSep "\n") | ||||
|         ]) | ||||
|         (if (post_comment != "") then makeComment post_comment else null) | ||||
|       ]); | ||||
|  | ||||
|       content = lib.concatMapStringsSep "\n\n" ruleToString value; | ||||
|     in pkgs.writeText name content; | ||||
|   }; | ||||
| in | ||||
| { | ||||
|   options.environment.robots-txt = lib.mkOption { | ||||
|     default = { }; | ||||
|     description = '' | ||||
|       Different instances of robots.txt to use with web services. | ||||
|     ''; | ||||
|     type = lib.types.attrsOf (lib.types.submodule ({ name, ... }: { | ||||
|       options = { | ||||
|         enable = lib.mkEnableOption "this instance of robots.txt" // { | ||||
|           default = true; | ||||
|         }; | ||||
|  | ||||
|         path = lib.mkOption { | ||||
|           description = "The resulting path of the dir containing the robots.txt file"; | ||||
|           type = lib.types.path; | ||||
|           readOnly = true; | ||||
|           default = "/etc/robots-txt/${name}"; | ||||
|         }; | ||||
|  | ||||
|         rules = lib.mkOption { | ||||
|           description = "Rules to include in robots.txt"; | ||||
|           default = [ ]; | ||||
|           example = [ | ||||
|             { User-agent = "Googlebot"; Disallow = "/no-googlebot"; } | ||||
|             { User-agent = "Bingbot"; Disallow = [ "/no-bingbot" "/no-bingbot2" ]; } | ||||
|           ]; | ||||
|           type = robots-txt-format.type; | ||||
|         }; | ||||
|  | ||||
|         virtualHost = lib.mkOption { | ||||
|           description = "An nginx virtual host to add the robots.txt to"; | ||||
|           type = lib.types.nullOr lib.types.str; | ||||
|           default = null; | ||||
|         }; | ||||
|       }; | ||||
|     })); | ||||
|   }; | ||||
|  | ||||
|   config = { | ||||
|     environment.etc = lib.mapAttrs' (name: value: { | ||||
|       name = "robots-txt/${name}/robots.txt"; | ||||
|       value.source = robots-txt-format.generate name value.rules; | ||||
|     }) cfg; | ||||
|  | ||||
|     services.nginx.virtualHosts = lib.pipe cfg [ | ||||
|       (lib.filterAttrs (_: value: value.virtualHost != null)) | ||||
|       (lib.mapAttrs' (name: value: { | ||||
|         name = value.virtualHost; | ||||
|         value = { | ||||
|           locations = { | ||||
|             "= /robots.txt" = { | ||||
|               extraConfig = '' | ||||
|                 add_header Content-Type text/plain; | ||||
|               ''; | ||||
|               root = cfg.${name}.path; | ||||
|             }; | ||||
|           }; | ||||
|         }; | ||||
|       })) | ||||
|     ]; | ||||
|   }; | ||||
| } | ||||
| @@ -12,7 +12,7 @@ let | ||||
|     name | ||||
|   , commit | ||||
|   , hash | ||||
|   , tracking-branch ? "REL1_41" | ||||
|   , tracking-branch ? "REL1_42" | ||||
|   , kebab-name ? kebab-case-name name | ||||
|   , fetchgit ? pkgs.fetchgit | ||||
|   }: | ||||
| @@ -33,63 +33,63 @@ in | ||||
| lib.mergeAttrsList [ | ||||
|   (mw-ext { | ||||
|     name = "CodeEditor"; | ||||
|     commit = "7d8447035e381d76387e38b92e4d1e2b8d373a01"; | ||||
|     hash = "sha256-v2AlbP0vZma3qZyEAWGjZ/rLcvOpIMroyc1EixKjlAU="; | ||||
|     commit = "9f69f2cf7616342d236726608a702d651b611938"; | ||||
|     hash = "sha256-sRaYj34+7aghJUw18RoowzEiMx0aOANU1a7YT8jivBw="; | ||||
|   }) | ||||
|   (mw-ext { | ||||
|     name = "CodeMirror"; | ||||
|     commit = "a7b4541089f9b88a0b722d9d790e4cf0f13aa328"; | ||||
|     hash = "sha256-clyzN3v3+J4GjdyhrCsytBrH7VR1tq5yd0rB+32eWCg="; | ||||
|     commit = "1a1048c770795789676adcf8a33c1b69f6f5d3ae"; | ||||
|     hash = "sha256-Y5ePrtLNiko2uU/sesm8jdYmxZkYzQDHfkIG1Q0v47I="; | ||||
|   }) | ||||
|   (mw-ext { | ||||
|     name = "DeleteBatch"; | ||||
|     commit = "cad869fbd95637902673f744581b29e0f3e3f61a"; | ||||
|     hash = "sha256-M1ek1WdO1/uTjeYlrk3Tz+nlb/fFZH+O0Ok7b10iKak="; | ||||
|     commit = "b76bb482e026453079104d00f9675b4ab851947e"; | ||||
|     hash = "sha256-GebF9B3RVwpPw8CYKDDT6zHv/MrrzV6h2TEIvNlRmcw="; | ||||
|   }) | ||||
|   (mw-ext { | ||||
|     name = "PluggableAuth"; | ||||
|     commit = "4111a57c34e25bde579cce5d14ea094021e450c8"; | ||||
|     hash = "sha256-aPtN8A9gDxLlq2+EloRZBO0DfHtE0E5kbV/adk82jvM="; | ||||
|     commit = "1da98f447fd8321316d4286d8106953a6665f1cc"; | ||||
|     hash = "sha256-DKDVcAfWL90FmZbSsdx1J5PkGu47EsDQmjlCpcgLCn4="; | ||||
|   }) | ||||
|   (mw-ext { | ||||
|     name = "Popups"; | ||||
|     commit = "f1bcadbd8b868f32ed189feff232c47966c2c49e"; | ||||
|     hash = "sha256-PQAjq/X4ZYwnnZ6ADCp3uGWMIucJy0ZXxsTTbAyxlSE="; | ||||
|     commit = "9b9e986316b9662b1b45ce307a58dd0320dd33cf"; | ||||
|     hash = "sha256-rSOZHT3yFIxA3tPhIvztwMSmSef/XHKmNfQl1JtGrUA="; | ||||
|   }) | ||||
|   (mw-ext { | ||||
|     name = "Scribunto"; | ||||
|     commit = "7b99c95f588b06635ee3c487080d6cb04617d4b5"; | ||||
|     hash = "sha256-pviueRHQAsSlv4AtnUpo2Cjci7CbJ5aM75taEXY+WrI="; | ||||
|     commit = "eb6a987e90db47b09b0454fd06cddb69fdde9c40"; | ||||
|     hash = "sha256-Nr0ZLIrS5jnpiBgGnd90lzi6KshcsxeC+xGmNsB/g88="; | ||||
|   }) | ||||
|   (mw-ext { | ||||
|     name = "SimpleSAMLphp"; | ||||
|     kebab-name = "simple-saml-php"; | ||||
|     commit = "ecb47191fecd1e0dc4c9d8b90a9118e393d82c23"; | ||||
|     hash = "sha256-gKu+O49XrAVt6hXdt36Ru7snjsKX6g2CYJ0kk/d+CI8="; | ||||
|     commit = "fd4d49cf48d16efdb91ae8128cdd507efe84d311"; | ||||
|     hash = "sha256-Qdtroew2j3AsZYlhAAUKQXXS2kUzUeQFnuR6ZHdFhAQ="; | ||||
|   }) | ||||
|   (mw-ext { | ||||
|     name = "TemplateData"; | ||||
|     commit = "1ec66ce80f8a4322138efa56864502d0ee069bad"; | ||||
|     hash = "sha256-Lv3Lq9dYAtdgWcwelveTuOhkP38MTu0m5kmW8+ltRis="; | ||||
|     commit = "836e3ca277301addd2578b2e746498ff6eb8e574"; | ||||
|     hash = "sha256-UMcRLYxYn+AormwTYjKjjZZjA806goMY2TRQ4KoS5fY="; | ||||
|   }) | ||||
|   (mw-ext { | ||||
|     name = "TemplateStyles"; | ||||
|     commit = "581180e898d6a942e2a65c8f13435a5d50fffa67"; | ||||
|     hash = "sha256-zW8O0mzG4jYfQoKi2KzsP+8iwRCLnWgH7qfmDE2R+HU="; | ||||
|     commit = "06a2587689eba0a17945fd9bd4bb61674d3a7853"; | ||||
|     hash = "sha256-C7j0jCkMeVZiLKpk+55X+lLnbG4aeH+hWIm3P5fF4fw="; | ||||
|   }) | ||||
|   (mw-ext { | ||||
|     name = "UserMerge"; | ||||
|     commit = "c17c919bdb9b67bb69f80df43e9ee9d33b1ecf1b"; | ||||
|     hash = "sha256-+mkzTCo8RVlGoFyfCrSb5YMh4J6Pbi1PZLFu5ps8bWY="; | ||||
|     commit = "41759d0c61377074d159f7d84130a095822bc7a3"; | ||||
|     hash = "sha256-pGjA7r30StRw4ff0QzzZYUhgD3dC3ZuiidoSEz8kA8Q="; | ||||
|   }) | ||||
|   (mw-ext { | ||||
|     name = "VisualEditor"; | ||||
|     commit = "90bb3d455892e25317029ffd4bda93159e8faac8"; | ||||
|     hash = "sha256-SZAVELQUKZtwSM6NVlxvIHdFPodko8fhZ/uwB0LCFDA="; | ||||
|     commit = "a128b11fe109aa882de5a40d2be0cdd0947ab11b"; | ||||
|     hash = "sha256-bv1TkomouOxe+DKzthyLyppdEUFSXJ9uE0zsteVU+D4="; | ||||
|   }) | ||||
|   (mw-ext { | ||||
|     name = "WikiEditor"; | ||||
|     commit = "8dba5b13246d7ae09193f87e6273432b3264de5f"; | ||||
|     hash = "sha256-vF9PBuM+VfOIs/a2X1JcPn6WH4GqP/vUJDFkfXzWyFU="; | ||||
|     commit = "21383e39a4c9169000acd03edfbbeec4451d7974"; | ||||
|     hash = "sha256-aPVpE6e4qLLliN9U5TA36e8tFrIt7Fl8RT1cGPUWoNI="; | ||||
|   }) | ||||
| ] | ||||
|   | ||||
| @@ -1,8 +1,8 @@ | ||||
| gitea: | ||||
|     runners: | ||||
|         alpha: ENC[AES256_GCM,data:aAFv+/ygC7oxGT3qnoEf+AZL3Nk1yOq3HupL9l0j8P913GefPKqlBt/mbuRVug==,iv:usXElENwbOHxUdoqHScK7PjeZavXUwoxpQWEMjxU2u4=,tag:E8OzZ9pmxIru7Glgh7v0lg==,type:str] | ||||
|         beta: ENC[AES256_GCM,data:riRSBDzX9DAxKl2UCds1ANddl3ij+byAgigOafJ5RjWl8cNVlowK21klBiKTxw==,iv:clijEUKX9o52p5A94eEW0f8qGGhFpy/LFe+uQG/iQLg=,tag:PchXbsZMnW//O7brEAEeWw==,type:str] | ||||
|         epsilon: ENC[AES256_GCM,data:lUt8uaqh9eC1IdIUfiw3dzxcDErSWaiT9lzg4ONf/QZeXj7Do7Es0GXBFd41Hw==,iv:hPm5Lez5ISHIlw1+i4z/oBsh4H5ZXPVYnXXSGq1eal0=,tag:/KcmPw30622tN9ruMUwfUw==,type:str] | ||||
|         alpha: ENC[AES256_GCM,data:Hnq2guka4oERPIFCv1/ggrLjaePA7907VHXMStDQ7ll3hntTioT76qGOUJgfIw==,iv:wDPYuuL6VAWJakrz6asVRrzwRxqw0JDRes13MgJIT6E=,tag:ogFUeUirHVkCLN63nctxOw==,type:str] | ||||
|         beta: ENC[AES256_GCM,data:HmdjBvW8eO5MkzXf7KEzSNQAptF/RKN8Bh03Ru7Ru/Ky+eJJtk91aqSSIjFa+Q==,iv:Hz9HE3U6CFfZFcPmYMd6wSzZkSvszt92L2gV+pUlMis=,tag:LG3NfsS7B1EdRFvnP3XESQ==,type:str] | ||||
|         epsilon: ENC[AES256_GCM,data:wfGxwWwDzb6AJaFnxe/93WNZGtuTpCkLci/Cc5MTCTKJz6XlNuy3m/1Xsnw0hA==,iv:I6Zl+4BBAUTXym2qUlFfdnoLTHShu+VyxPMjRlFzMis=,tag:jjTyZs1Nzqlhjd8rAldxDw==,type:str] | ||||
| sops: | ||||
|     kms: [] | ||||
|     gcp_kms: [] | ||||
| @@ -63,8 +63,8 @@ sops: | ||||
|             aU4xWjVYYlNvSmYxajVGdzk5dTQ4WG8Klq12bSegsW29xp4qteuCB5Tzis6EhVCk | ||||
|             53jqtYe5UG9MjFVQYiSi2jJz5/dxfqSINMZ/Y/EB5LxbwgbFws8Yuw== | ||||
|             -----END AGE ENCRYPTED FILE----- | ||||
|     lastmodified: "2024-12-09T21:17:40Z" | ||||
|     mac: ENC[AES256_GCM,data:HensJbPU1Kx9aQNUhdtFkX/6qdxj7yby6GeSruOT+HYEtoq0py/zvMtdCqmfjc4AOptYlXdgK7w30P976dG1esjlYwF07qtVvAbUqvExkksuV4zp81VKHMXUOAyiQK79kLe3rx6cvEdUDbOjZOsxN02eRrcanN+7rJS6f7vNN88=,iv:PlePCik6JcOtVBQhhOj9khhp2LwwfXBwAGpzu4ywhTA=,tag:Clz+xX1Cffs8Zpv2LdsGVA==,type:str] | ||||
|     lastmodified: "2024-12-12T12:20:19Z" | ||||
|     mac: ENC[AES256_GCM,data:D9/NAd/zrF6pHFdZjTUqI+u4WiwJqt0w5Y+SYCS1o/dAXJE/ajHzse/vCSGXZIjP0yqe+S/NyTvhf+stw2B4dk6Njtabjd+PhG0hR4L0X07FtFqzB3u5pLHCb0bH9QLG5zWcyMkwNiNTCvhRUZzbcqLEGqqJ7ZjZAEUfYSR+Jls=,iv:5xPfODPxtQjgbl8delUHsmhD0TI2gHjrxpHV+qiFE00=,tag:HHLo5G8jhy/sKB3R+sKmwQ==,type:str] | ||||
|     pgp: | ||||
|         - created_at: "2024-12-09T21:17:27Z" | ||||
|           enc: |- | ||||
| @@ -87,4 +87,4 @@ sops: | ||||
|             -----END PGP MESSAGE----- | ||||
|           fp: F7D37890228A907440E1FD4846B9228E814A2AAC | ||||
|     unencrypted_suffix: _unencrypted | ||||
|     version: 3.8.1 | ||||
|     version: 3.9.2 | ||||
|   | ||||
							
								
								
									
										20
									
								
								shell.nix
									
									
									
									
									
								
							
							
						
						
									
										20
									
								
								shell.nix
									
									
									
									
									
								
							| @@ -11,14 +11,14 @@ pkgs.mkShellNoCC { | ||||
|     editorconfig-checker | ||||
|   ]; | ||||
|  | ||||
|   shellHook = '' | ||||
|     export OS_AUTH_URL=https://api.stack.it.ntnu.no:5000 | ||||
|     export OS_PROJECT_ID=b78432a088954cdc850976db13cfd61c | ||||
|     export OS_PROJECT_NAME="STUDORG_Programvareverkstedet" | ||||
|     export OS_USER_DOMAIN_NAME="NTNU" | ||||
|     export OS_PROJECT_DOMAIN_ID="d3f99bcdaf974685ad0c74c2e5d259db" | ||||
|     export OS_REGION_NAME="NTNU-IT" | ||||
|     export OS_INTERFACE=public | ||||
|     export OS_IDENTITY_API_VERSION=3 | ||||
|   ''; | ||||
|   env = { | ||||
|     OS_AUTH_URL = "https://api.stack.it.ntnu.no:5000"; | ||||
|     OS_PROJECT_ID = "b78432a088954cdc850976db13cfd61c"; | ||||
|     OS_PROJECT_NAME = "STUDORG_Programvareverkstedet"; | ||||
|     OS_USER_DOMAIN_NAME = "NTNU"; | ||||
|     OS_PROJECT_DOMAIN_ID = "d3f99bcdaf974685ad0c74c2e5d259db"; | ||||
|     OS_REGION_NAME = "NTNU-IT"; | ||||
|     OS_INTERFACE = "public"; | ||||
|     OS_IDENTITY_API_VERSION = "3"; | ||||
|   }; | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user