From 5a52d9ec6cad8da8f49c515025e6e3ec4efa44a5 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Tue, 6 Dec 2022 14:49:24 +0100 Subject: [PATCH] mail: Set up vdirsyncer for caldav/carddav Set up vdirsyncer to have synchronization with my nextcloud instance. Pulls credentials from local pass set up and always gives priority to remote instances so nothing gets lost on local data issues. --- mail/.config/vdirsyncer/config | 39 ++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 mail/.config/vdirsyncer/config diff --git a/mail/.config/vdirsyncer/config b/mail/.config/vdirsyncer/config new file mode 100644 index 0000000..8bf14f1 --- /dev/null +++ b/mail/.config/vdirsyncer/config @@ -0,0 +1,39 @@ +[general] +status_path = "~/.local/vdirsyncer/status/" + +[pair calendar] +a = "calendar_local" +b = "calendar_nextcloud" +collections = ["from a", "from b"] +metadata = ["displayname", "color"] +conflict_resolution = "b wins" + +[storage calendar_local] +type = "filesystem" +path = "~/documents/calendars/" +fileext = ".ics" + +[storage calendar_nextcloud] +type = "caldav" +url = "https://files.martyoeh.me/remote.php/dav/" +username.fetch = ["shell", "pass personal/files.martyoeh.me/me | awk -F': ' '{print $2}'"] +password.fetch = ["shell", "pass personal/files.martyoeh.me/me | head -n1"] + +[pair contacts] +a = "contacts_local" +b = "contacts_nextcloud" +collections = ["from a", "from b"] +metadata = ["displayname", "description"] +conflict_resolution = "b wins" + +[storage contacts_local] +type = "filesystem" +path = "~/documents/contacts/" +fileext = ".vcf" + +[storage contacts_nextcloud] +type = "carddav" +url = "https://files.martyoeh.me/remote.php/dav/" +username.fetch = ["shell", "pass personal/files.martyoeh.me/me | awk -F': ' '{print $2}'"] +password.fetch = ["shell", "pass personal/files.martyoeh.me/me | head -n1"] +