Prep git forge

This commit is contained in:
Daniel Flanagan 2024-09-06 15:39:26 -05:00
parent 6f1b5bb86d
commit 72a49c2f28

View file

@ -739,106 +739,116 @@ sudo nix run nixpkgs#ipmitool -- raw 0x30 0x30 0x02 0xff 0x00
# acmeCA = "https://acme-staging-v02.api.letsencrypt.org/directory"; # acmeCA = "https://acme-staging-v02.api.letsencrypt.org/directory";
}; };
} }
# { {
# services.forgejo = { systemd.tmpfiles.settings = {
# enable = true; "10-backups" = {
# stateDir = "/storage/forgejo"; "/storage/forgejo" = {
# settings = { "d" = {
# DEFAULT = { mode = "0700";
# APP_NAME = "git.lyte.dev"; user = "forgejo";
# }; group = "nogroup";
# server = { };
# ROOT_URL = "https://git.lyte.dev"; };
# HTTP_ADDR = "127.0.0.1"; };
# HTTP_PORT = 3088; };
# DOMAIN = "git.lyte.dev"; services.forgejo = {
# }; enable = false;
# actions = { stateDir = "/storage/forgejo";
# ENABLED = true; settings = {
# }; DEFAULT = {
# service = { APP_NAME = "git.lyte.dev";
# DISABLE_REGISTRATION = true; };
# }; server = {
# session = { ROOT_URL = "https://git.lyte.dev";
# COOKIE_SECURE = true; HTTP_ADDR = "127.0.0.1";
# }; HTTP_PORT = 3088;
# log = { DOMAIN = "git.lyte.dev";
# # TODO: raise the log level };
# # LEVEL = "Debug"; actions = {
# }; ENABLED = true;
# ui = { };
# THEMES = "forgejo-auto,forgejo-light,forgejo-dark,catppuccin-mocha-sapphire"; service = {
# DEFAULT_THEME = "forgejo-auto"; DISABLE_REGISTRATION = true;
# }; };
# indexer = { session = {
# REPO_INDEXER_ENABLED = "true"; COOKIE_SECURE = true;
# REPO_INDEXER_PATH = "indexers/repos.bleve"; };
# MAX_FILE_SIZE = "1048576"; log = {
# # REPO_INDEXER_INCLUDE = # LEVEL = "Debug";
# REPO_INDEXER_EXCLUDE = "resources/bin/**"; };
# }; ui = {
# }; THEMES = "forgejo-auto,forgejo-light,forgejo-dark";
# lfs = { DEFAULT_THEME = "forgejo-auto";
# enable = true; };
# }; indexer = {
# dump = { REPO_INDEXER_ENABLED = "true";
# enable = true; REPO_INDEXER_PATH = "indexers/repos.bleve";
# }; MAX_FILE_SIZE = "1048576";
# database = { # REPO_INDEXER_INCLUDE =
# # TODO: move to postgres? REPO_INDEXER_EXCLUDE = "resources/bin/**";
# type = "sqlite3"; };
# }; };
# }; lfs = {
# services.gitea-actions-runner = { enable = true;
# # TODO: simple git-based automation would be dope? maybe especially for };
# # mirroring to github super easy? dump = {
# # enable = true; enable = true;
# package = pkgs.forgejo-runner; };
# instances."beefcake" = { database = {
# enable = true; # TODO: move to postgres?
# name = "beefcake"; type = "sqlite3";
# url = "https://git.lyte.dev"; };
# settings = { };
# container = { services.gitea-actions-runner = {
# # use the shared network which is bridged by default # TODO: simple git-based automation would be dope? maybe especially for
# # this lets us hit git.lyte.dev just fine # mirroring to github super easy?
# network = "podman"; # enable = true;
# }; package = pkgs.forgejo-runner;
# }; instances."beefcake" = {
# labels = [ enable = false;
# # type ":host" does not depend on docker/podman/lxc name = "beefcake";
# "podman" url = "https://git.lyte.dev";
# "nix:docker://git.lyte.dev/lytedev/nix:latest" settings = {
# "beefcake:host" container = {
# "nixos-host:host" # use the shared network which is bridged by default
# ]; # this lets us hit git.lyte.dev just fine
# tokenFile = config.sops.secrets."forgejo-runner.env".path; network = "podman";
# hostPackages = with pkgs; [ };
# nix };
# bash labels = [
# coreutils # type ":host" does not depend on docker/podman/lxc
# curl "podman"
# gawk "nix:docker://git.lyte.dev/lytedev/nix:latest"
# gitMinimal "beefcake:host"
# gnused "nixos-host:host"
# nodejs ];
# gnutar # needed for cache action tokenFile = config.sops.secrets."forgejo-runner.env".path;
# wget hostPackages = with pkgs; [
# ]; nix
# }; bash
# }; coreutils
# # environment.systemPackages = with pkgs; [nodejs]; curl
# services.caddy.virtualHosts."git.lyte.dev" = { gawk
# extraConfig = '' gitMinimal
# reverse_proxy :${toString config.services.forgejo.settings.server.HTTP_PORT} gnused
# ''; nodejs
# }; gnutar # needed for cache action
# services.caddy.virtualHosts."http://git.beefcake.lan" = { wget
# extraConfig = '' ];
# reverse_proxy :${toString config.services.forgejo.settings.server.HTTP_PORT} };
# ''; };
# }; # environment.systemPackages = with pkgs; [nodejs];
# } services.caddy.virtualHosts."git.lyte.dev" = {
extraConfig = ''
reverse_proxy :${toString config.services.forgejo.settings.server.HTTP_PORT}
'';
};
services.caddy.virtualHosts."http://git.beefcake.lan" = {
extraConfig = ''
reverse_proxy :${toString config.services.forgejo.settings.server.HTTP_PORT}
'';
};
}
# { # {
# services.vaultwarden = { # services.vaultwarden = {
# enable = true; # enable = true;