aboutsummaryrefslogtreecommitdiffstats
path: root/roles/cgit/templates
diff options
context:
space:
mode:
Diffstat (limited to 'roles/cgit/templates')
-rw-r--r--roles/cgit/templates/cgit.httpd.conf.j217
-rw-r--r--roles/cgit/templates/cgitrc.j237
2 files changed, 54 insertions, 0 deletions
diff --git a/roles/cgit/templates/cgit.httpd.conf.j2 b/roles/cgit/templates/cgit.httpd.conf.j2
new file mode 100644
index 0000000..a8b4707
--- /dev/null
+++ b/roles/cgit/templates/cgit.httpd.conf.j2
@@ -0,0 +1,17 @@
+
+# httpd ~~ /etc/httpd.d/cgit.conf"
+# managed by Ansible
+
+ext_ip="0.0.0.0"
+server "cgit" {
+ listen on $ext_ip port {{ cgit_port }}
+
+ # serve cgit static files directly: cgit.css and cgit.png
+ location "/cgit.*" {
+ root "/cgit"
+ no fastcgi
+ }
+ # cgit CGI
+ root "/cgi-bin/cgit.cgi"
+ fastcgi socket "/run/slowcgi.sock"
+}
diff --git a/roles/cgit/templates/cgitrc.j2 b/roles/cgit/templates/cgitrc.j2
new file mode 100644
index 0000000..1c316f3
--- /dev/null
+++ b/roles/cgit/templates/cgitrc.j2
@@ -0,0 +1,37 @@
+
+# cgit ~~ /var/www/conf/cgitrc
+# managed by Ansible
+
+# visuals
+css={{ cgit_config_css }}
+logo={{ cgit_config_logo }}
+favicon={{ cgit_config_favicon }}
+
+# readme
+readme=:README.md
+readme=:README.org
+readme=:README
+about-filter=/bin/about-filter.sh
+
+# features
+enable-commit-graph=1
+enable-http-clone=1
+enable-index-links=1
+max-stats=quarter
+robots=noindex, nofollow
+
+# git
+clone-url=git://git.{{ global.domain_name }}/$CGIT_REPO_URL ssh://git@git.{{ global.domain_name }}/$CGIT_REPO_URL http://git.{{ global.domain_name }}/$CGIT_REPO_URL
+
+# instance id
+root-title=git.{{ global.domain_name }}
+root-desc={{ cgit_config_root_desc }}
+root-readme={{ cgit_config_root_readme }}
+
+# archives
+snapshots=tar.gz
+
+# sections
+section-from-path=1
+section-sort=1
+scan-path={{ cgit_git_dir_chroot }}
remember that computers suck.