diff options
| author | Paul Buetow <paul@buetow.org> | 2025-09-11 20:25:28 +0300 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2025-09-11 20:25:28 +0300 |
| commit | 938931b12c0017cd8e7b9bd2adef176dd3524c74 (patch) | |
| tree | fbc06453c96391e58f3929134baef4d561ae154f | |
| parent | 893faf6252509790d14490325a92b26b7fa0817d (diff) | |
joern.buetow.org
| -rw-r--r-- | frontends/Rexfile | 13 | ||||
| -rw-r--r-- | frontends/etc/httpd.conf.tpl | 13 | ||||
| -rw-r--r-- | frontends/etc/rsyncd.conf.tpl | 36 | ||||
| -rw-r--r-- | frontends/scripts/rsync.sh.tpl | 6 | ||||
| -rw-r--r-- | frontends/var/nsd/zones/master/buetow.org.zone.tpl | 5 |
5 files changed, 51 insertions, 22 deletions
diff --git a/frontends/Rexfile b/frontends/Rexfile index 93d148a..0079387 100644 --- a/frontends/Rexfile +++ b/frontends/Rexfile @@ -83,7 +83,7 @@ our @f3s_hosts = # push @f3s_hosts, 'registry.f3s.buetow.org'; our @acme_hosts = - qw/buetow.org git.buetow.org paul.buetow.org dory.buetow.org ecat.buetow.org blog.buetow.org fotos.buetow.org znc.buetow.org dtail.dev foo.zone stats.foo.zone irregular.ninja alt.irregular.ninja snonux.foo/; + qw/buetow.org git.buetow.org paul.buetow.org joern.buetow.org dory.buetow.org ecat.buetow.org blog.buetow.org fotos.buetow.org znc.buetow.org dtail.dev foo.zone stats.foo.zone irregular.ninja alt.irregular.ninja snonux.foo/; push @acme_hosts, @f3s_hosts; # UTILITY TASKS @@ -131,6 +131,9 @@ task 'rsync', sub { pkg 'rsync', ensure => present; + # Not required, as we use rsyncd via inetd + # append_if_no_such_line '/etc/rc.conf.local', 'rsyncd_flags='; + file '/etc/rsyncd.conf', content => template('./etc/rsyncd.conf.tpl'), owner => 'root', @@ -143,7 +146,13 @@ task 'rsync', group => 'wheel', mode => '755'; - append_if_no_such_line '/etc/daily.local', '/usr/local/bin/rsync.sh'; + file '/tmp/rsync.cron', + ensure => 'file', + content => "*/5\t*\t*\t*\t*\t-ns /usr/local/bin/rsync.sh", + mode => '600'; + + run '{ crontab -l -u root ; cat /tmp/rsync.cron; } | uniq | crontab -u root -'; + run 'rm /tmp/rsync.cron'; }; desc 'Configure the gemtexter sites'; diff --git a/frontends/etc/httpd.conf.tpl b/frontends/etc/httpd.conf.tpl index 68946fd..c3a2764 100644 --- a/frontends/etc/httpd.conf.tpl +++ b/frontends/etc/httpd.conf.tpl @@ -125,6 +125,18 @@ server "<%= $prefix %>alt.irregular.ninja" { } <% } -%> +# joern special host +<% for my $prefix (@prefixes) { -%> +server "<%= $prefix %>joern.buetow.org" { + listen on * port 8080 + log style forwarded + location * { + root "/htdocs/joern/" + directory auto index + } +} +<% } -%> + # Dory special host <% for my $prefix (@prefixes) { -%> server "<%= $prefix %>dory.buetow.org" { @@ -137,6 +149,7 @@ server "<%= $prefix %>dory.buetow.org" { } <% } -%> +# ecat special host <% for my $prefix (@prefixes) { -%> server "<%= $prefix %>ecat.buetow.org" { listen on * port 8080 diff --git a/frontends/etc/rsyncd.conf.tpl b/frontends/etc/rsyncd.conf.tpl index 2798695..e9fe3cf 100644 --- a/frontends/etc/rsyncd.conf.tpl +++ b/frontends/etc/rsyncd.conf.tpl @@ -1,28 +1,28 @@ -<% my $allow = '*.buetow.org,localhost'; %> +<% my $allow = '*.wg0.wan.buetow.org,*.wg0,localhost'; %> max connections = 5 timeout = 300 -[publicgemini] -comment = Public Gemini capsule content -path = /var/gemini +[joernshtdocs] +comment = Joerns htdocs +path = /var/www/htdocs/joern read only = yes list = yes uid = www gid = www hosts allow = <%= $allow %> -[publichttp] -comment = Public HTTP content -path = /var/www/htdocs -read only = yes -list = yes -uid = www -gid = www -hosts allow = <%= $allow %> +# [publicgemini] +# comment = Public Gemini capsule content +# path = /var/gemini +# read only = yes +# list = yes +# uid = www +# gid = www +# hosts allow = <%= $allow %> -[sslcerts] -comment = TLS certificates -path = /etc/ssl -read only = yes -list = yes -hosts allow = <%= $allow %> +# [sslcerts] +# comment = TLS certificates +# path = /etc/ssl +# read only = yes +# list = yes +# hosts allow = <%= $allow %> diff --git a/frontends/scripts/rsync.sh.tpl b/frontends/scripts/rsync.sh.tpl index 8d7004b..c8d7b00 100644 --- a/frontends/scripts/rsync.sh.tpl +++ b/frontends/scripts/rsync.sh.tpl @@ -2,5 +2,7 @@ PATH=$PATH:/usr/local/bin -# disabled, as pulled directly from codeberg now -exit 0 +# Sync Joern's content over to Fishfinger! +if [ `hostname -s` = fishfinger ]; then + rsync -av --delete rsync://blowfish.wg0.wan.buetow.org/joernshtdocs/ /var/www/htdocs/joern/ +fi diff --git a/frontends/var/nsd/zones/master/buetow.org.zone.tpl b/frontends/var/nsd/zones/master/buetow.org.zone.tpl index 52f49c5..0a0fb36 100644 --- a/frontends/var/nsd/zones/master/buetow.org.zone.tpl +++ b/frontends/var/nsd/zones/master/buetow.org.zone.tpl @@ -56,6 +56,11 @@ standby.<%= $host %>. 300 IN A <%= $ips->{current_standby}{ipv4} %> ; Enable fai standby.<%= $host %>. 300 IN AAAA <%= $ips->{current_standby}{ipv6} %> ; Enable failover <% } -%> +; So joern can directly preview the content before rsync happens from blowfish to fishfinger +joern IN CNAME blowfish +www.joern IN CNAME blowfish +standby.joern IN CNAME fishfinger + dory 300 IN A <%= $ips->{current_master}{ipv4} %> ; Enable failover dory 300 IN AAAA <%= $ips->{current_master}{ipv6} %> ; Enable failover www.dory 300 IN A <%= $ips->{current_master}{ipv4} %> ; Enable failover |
