From b232b894c3cbe087c8d504e91637dcf62199eed1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Romain=20Gon=C3=A7alves?= <me@rgoncalves.se>
Date: Thu, 29 Jul 2021 17:00:20 +0200
Subject: Bump to third revision of homelab

---
 roles/cgit/templates/conf-cgitrc.j2           | 41 +++++++++++++++++++++++++++
 roles/cgit/templates/conf-footer.html.j2      |  3 ++
 roles/cgit/templates/etc-httpd.d-cgit.conf.j2 | 10 +++----
 roles/cgit/templates/var-www-conf-cgitrc.j2   | 39 -------------------------
 4 files changed, 49 insertions(+), 44 deletions(-)
 create mode 100644 roles/cgit/templates/conf-cgitrc.j2
 create mode 100644 roles/cgit/templates/conf-footer.html.j2
 delete mode 100644 roles/cgit/templates/var-www-conf-cgitrc.j2

(limited to 'roles/cgit/templates')

diff --git a/roles/cgit/templates/conf-cgitrc.j2 b/roles/cgit/templates/conf-cgitrc.j2
new file mode 100644
index 0000000..1fc283f
--- /dev/null
+++ b/roles/cgit/templates/conf-cgitrc.j2
@@ -0,0 +1,41 @@
+
+# cgit ~~ /var/www/conf/cgitrc
+# managed by Ansible
+
+# visuals
+css={{ cgit__css }}
+logo={{ cgit__logo }}
+favicon={{ cgit__favicon }}
+footer={{ cgit__footer }}
+
+# readme
+readme=:README.md
+readme=:README.org
+readme=:README
+readme=:.README.md
+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
+localtime=1
+
+# 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__root_desc }}
+root-readme={{ cgit__root_readme }}
+
+# archives
+snapshots=tar.gz
+
+# sections
+section-from-path=1
+section-sort=1
+scan-path={{ cgit_git_dir }}
diff --git a/roles/cgit/templates/conf-footer.html.j2 b/roles/cgit/templates/conf-footer.html.j2
new file mode 100644
index 0000000..66ca627
--- /dev/null
+++ b/roles/cgit/templates/conf-footer.html.j2
@@ -0,0 +1,3 @@
+<span style="background-color:yellow">
+remember that computers suck.
+</span>
diff --git a/roles/cgit/templates/etc-httpd.d-cgit.conf.j2 b/roles/cgit/templates/etc-httpd.d-cgit.conf.j2
index 6fb8e98..b77ca35 100644
--- a/roles/cgit/templates/etc-httpd.d-cgit.conf.j2
+++ b/roles/cgit/templates/etc-httpd.d-cgit.conf.j2
@@ -2,19 +2,19 @@
 # httpd ~~ /etc/httpd.d/cgit.conf"
 # managed by Ansible
 
-ext_ip="0.0.0.0"
 server "cgit" {
-	listen on $ext_ip port {{ cgit_port }}
+	listen on "{{ cgit_ip }}" port {{ cgit_port }}
 {% if cgit_authenticate %}
 	authenticate "realm" with "/htpasswd/cgit"
 {% endif %}
 
-	# serve cgit static files directly: cgit.css and cgit.png
+	# cgit
 	location "/cgit.*" {
 		root "/cgit"
-			no fastcgi	
+		no fastcgi
 	}
-	# cgit CGI
+
+	# fastcgi
 	root "/cgi-bin/cgit.cgi"
 	fastcgi socket "/run/slowcgi.sock"
 }
diff --git a/roles/cgit/templates/var-www-conf-cgitrc.j2 b/roles/cgit/templates/var-www-conf-cgitrc.j2
deleted file mode 100644
index 8be36ce..0000000
--- a/roles/cgit/templates/var-www-conf-cgitrc.j2
+++ /dev/null
@@ -1,39 +0,0 @@
-
-# cgit ~~ /var/www/conf/cgitrc
-# managed by Ansible
-
-# visuals
-css={{ cgit__css }}
-logo={{ cgit__logo }}
-favicon={{ cgit__favicon }}
-
-# readme
-readme=:README.md
-readme=:README.org
-readme=:README
-readme=:.README.md
-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__root_desc }}
-root-readme={{ cgit__root_readme }}
-
-# archives
-snapshots=tar.gz
-
-# sections
-section-from-path=1
-section-sort=1
-scan-path={{ cgit_git_dir_chroot }}
-- 
cgit v1.2.3