Move Nix files back to the root of the project
This commit is contained in:
parent
52044d9995
commit
087153a16d
223 changed files with 12 additions and 12 deletions
36
modules/nixos/homelab/gitea.nix
Normal file
36
modules/nixos/homelab/gitea.nix
Normal file
|
@ -0,0 +1,36 @@
|
|||
{ config, lib, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
port = 2222;
|
||||
in
|
||||
{
|
||||
options.nixosModules.gitea.enable = mkEnableOption "Enable gitea";
|
||||
|
||||
config = mkIf config.nixosModules.gitea.enable {
|
||||
services = {
|
||||
gitea = {
|
||||
enable = true;
|
||||
group = "media";
|
||||
stateDir = "/mnt/media/gitea";
|
||||
|
||||
settings = {
|
||||
server = {
|
||||
HTTP_PORT = port;
|
||||
};
|
||||
|
||||
service = {
|
||||
DISABLE_REGISTRATION = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
caddy.virtualHosts."gitea.oliverdavies.uk" = {
|
||||
useACMEHost = "oliverdavies.uk";
|
||||
|
||||
extraConfig = "reverse_proxy localhost:${toString port}";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue