You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
47 lines
1.1 KiB
47 lines
1.1 KiB
{ config, pkgs, ... }:
|
|
|
|
let port = 15150;
|
|
in
|
|
{
|
|
services.nginx.virtualHosts."git.spacekookie.de" = {
|
|
enableACME = false;
|
|
useACMEHost = "spacekookie.de";
|
|
forceSSL = true;
|
|
locations."/" = {
|
|
proxyPass = "http://localhost:${builtins.toString port}";
|
|
};
|
|
locations."/static/" = {
|
|
alias = "/var/lib/cgit/";
|
|
};
|
|
};
|
|
|
|
# cgit server
|
|
services.lighttpd = {
|
|
enable = true;
|
|
inherit port;
|
|
|
|
cgit = {
|
|
enable = true;
|
|
configText = ''
|
|
clone-prefix=https://git.spacekookie.de
|
|
css=/static/cgit.css
|
|
favicon=/static/favicon.ico
|
|
enable-commit-graph=1
|
|
enable-follow-links=1
|
|
enable-log-filecount=1
|
|
enable-log-linecount=1
|
|
enable-git-config=1
|
|
remove-suffix=1
|
|
readme=:README
|
|
readme=:README.md
|
|
about-filter=${pkgs.cgit}/lib/cgit/filters/about-formatting.sh
|
|
source-filter=${pkgs.cgit}/lib/cgit/filters/syntax-highlighting.py
|
|
root-title=git.spacekookie.de
|
|
root-desc=Here be really bad source code yarrr
|
|
scan-path=/home/spacekookie/git
|
|
'';
|
|
subdir = ""; # be on git.spacekookie.de
|
|
};
|
|
};
|
|
|
|
}
|
|
|