aboutsummaryrefslogtreecommitdiffstats
path: root/justfile
diff options
context:
space:
mode:
authorDavid Runge <dave@sleepmap.de>2022-04-30 12:47:43 +0200
committerDavid Runge <dave@sleepmap.de>2022-04-30 13:06:33 +0200
commit8e8d4bbf2f04ea3fb923cfaea9335c69023df546 (patch)
treee9e51840d16ef63f2f709f8ddac25a0debc24465 /justfile
parent561590db771c9248b6e39ddff7d80665ef8a90e8 (diff)
downloadwkd-8e8d4bbf2f04ea3fb923cfaea9335c69023df546.tar.gz
wkd-8e8d4bbf2f04ea3fb923cfaea9335c69023df546.tar.bz2
wkd-8e8d4bbf2f04ea3fb923cfaea9335c69023df546.tar.xz
wkd-8e8d4bbf2f04ea3fb923cfaea9335c69023df546.zip
Add justfile to generate direct WKD directory
justfile: Add just file to generate direct WKD directory using sq and automatically synchronize it with a remote server using rsync.
Diffstat (limited to 'justfile')
-rw-r--r--justfile17
1 files changed, 17 insertions, 0 deletions
diff --git a/justfile b/justfile
new file mode 100644
index 0000000..4b27943
--- /dev/null
+++ b/justfile
@@ -0,0 +1,17 @@
+fqdn := "sleepmap.de"
+remote := "dave@sleepmap.de"
+location := "/srv/http/wkd"
+
+default: create_wkd
+
+create_certring:
+ sq -f keyring join -o certrings/{{fqdn}}.asc certs/{{fqdn}}/*/*.asc
+
+create_fqdn_wkd_dir:
+ # create a direct directory (e.g. https://example.com/.well-known/openpgpkey/hu)
+ sq -f wkd generate -d output/{{fqdn}} {{fqdn}} certrings/{{fqdn}}.asc
+
+sync_wkd_dir:
+ rsync -rv --delete output/{{fqdn}}/ {{remote}}:{{location}}/{{fqdn}}
+
+create_wkd: create_certring create_fqdn_wkd_dir sync_wkd_dir