Switch to Forgejo from Gitea

This commit is contained in:
Evie Litherland-Smith 2024-03-31 18:06:01 +01:00
parent 7dbf3982b6
commit c7441b0a26
3 changed files with 29 additions and 8 deletions

View file

@ -178,7 +178,7 @@
systemModules = [
./services/nix-serve.nix
./services/caddy.nix
./services/gitea.nix
./services/forgejo.nix
./services/grafana.nix
./services/minecraft.nix
./services/sshd.nix

View file

@ -1,14 +1,13 @@
{config, ...}: {
{
config,
pkgs,
...
}: {
users.mutableUsers = false;
system.autoUpgrade = {
enable = true;
flake = "git+${config.nix.registry.nixos.to.url}";
flags = [
"--update-input"
"nixpkgs"
"--no-write-lock-file"
"-L" # print build logs
];
flags = ["-L"]; # Print build logs
dates = "02:00";
randomizedDelaySec = "15min";
allowReboot = true;
@ -17,4 +16,5 @@
upper = "05:00";
};
};
environment.systemPackages = with pkgs; [nil];
}

21
services/forgejo.nix Normal file
View file

@ -0,0 +1,21 @@
{...}: {
imports = [./caddy.nix];
services = {
forgejo = {
enable = true;
settings = {
server = {
ROOT_URL = "https://git.xenia.me.uk";
DOMAIN = "git.xenia.me.uk";
HTTP_ADDR = "127.0.0.1";
HTTP_PORT = 3100;
DISABLE_SSH = true;
};
ui = {DEFAULT_THEME = "auto";};
admin = {DISABLE_REGULAR_ORG_CREATION = true;};
service = {DISABLE_REGISTRATION = true;};
};
};
caddy.virtualHosts."git.xenia.me.uk".extraConfig = "reverse_proxy http://localhost:3100";
};
}