Added forgejo service to alexandria
This commit is contained in:
parent
2a232f059d
commit
35f5c43399
3 changed files with 64 additions and 34 deletions
32
hosts/servers/alexandria/forgejo.nix
Normal file
32
hosts/servers/alexandria/forgejo.nix
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
{ config, ... }:
|
||||
|
||||
let
|
||||
domain = "git.baduhai.dev";
|
||||
in
|
||||
|
||||
{
|
||||
services = {
|
||||
forgejo = {
|
||||
enable = true;
|
||||
settings = {
|
||||
session.COOKIE_SECURE = true;
|
||||
server = {
|
||||
PROTOCOL = "http+unix";
|
||||
DOMAIN = domain;
|
||||
SSH_DOMAIN = config.networking.domain;
|
||||
ROOT_URL = "https://${domain}";
|
||||
OFFLINE_MODE = true; # disable use of CDNs
|
||||
};
|
||||
log.LEVEL = "Warn";
|
||||
mailer.ENABLED = false;
|
||||
actions.ENABLED = false;
|
||||
};
|
||||
};
|
||||
nginx.virtualHosts.${domain} = {
|
||||
useACMEHost = "baduhai.dev";
|
||||
forceSSL = true;
|
||||
kTLS = true;
|
||||
locations."/".proxyPass = "http://unix:${config.services.forgejo.settings.server.HTTP_ADDR}:/";
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue