From ca27f46ffe8a126d48f6ee2196e4b68c4cb0fbd6 Mon Sep 17 00:00:00 2001 From: Magnus Andersson Date: Tue, 10 Oct 2023 10:48:43 +0200 Subject: [PATCH 1/7] listusers.sh: disabel tls verify for rclone mkdir because we use ip address with webdav. --- templates/mariadb_backup/listusers.erb.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/mariadb_backup/listusers.erb.sh b/templates/mariadb_backup/listusers.erb.sh index fc9c692..115115a 100644 --- a/templates/mariadb_backup/listusers.erb.sh +++ b/templates/mariadb_backup/listusers.erb.sh @@ -25,7 +25,7 @@ base_dir="${project}:${bucket}" mountpoint="/opt/statistics" customer_dir="${mountpoint}/${location}" mkdir -p "${customer_dir}" -rclone mkdir "${base_dir}/${location}" +rclone mkdir --no-check-certificate --webdav-headers "Host,sunet.drive.sunet.se" --use-cookies "${base_dir}/${location}" echo "${users}" | awk 'BEGIN{print "{"} {print t "\""$1"\": \""$2"\""} {t=","} END{print "}"}' | jq . >"${customer_dir}/users.json" status=0 From e990b054012ec3a731ab329286c84ebaf6c85af3 Mon Sep 17 00:00:00 2001 From: Richard Freitag Date: Fri, 6 Oct 2023 09:23:37 +0100 Subject: [PATCH 2/7] Change regex to send @.shh.se cases to external node --- .../application/mappingfile-test.json.erb | 110 +++++++++--------- 1 file changed, 55 insertions(+), 55 deletions(-) diff --git a/templates/application/mappingfile-test.json.erb b/templates/application/mappingfile-test.json.erb index a2c305a..18f0553 100644 --- a/templates/application/mappingfile-test.json.erb +++ b/templates/application/mappingfile-test.json.erb @@ -1,58 +1,58 @@ { - "/@(\\w*\\.)*antagning.se$/": "antagning.drive.test.sunet.se", - "/@(\\w*\\.)*bth.se$/": "bth.drive.test.sunet.se", - "/@(\\w*\\.)*chalmers.se$/": "chalmers.drive.test.sunet.se", - "/@(\\w*\\.)*du.se$/": "du.drive.test.sunet.se", - "/@(\\w*\\.)*eduid.se$/": "extern.drive.test.sunet.se", - "/@(\\w*\\.)*esh.se$/": "esh.drive.test.sunet.se", - "/@(\\w*\\.)*fhs.se$/": "fhs.drive.test.sunet.se", - "/@(\\w*\\.)*gih.se$/": "gih.drive.test.sunet.se", - "/@(\\w*\\.)*gu.se$/": "gu.drive.test.sunet.se", - "/@(\\w*\\.)*hb.se$/": "hb.drive.test.sunet.se", - "/@(\\w*\\.)*shh.se$/": "shh.drive.test.sunet.se", - "/@(\\w*\\.)*hh.se$/": "hh.drive.test.sunet.se", - "/@(\\w*\\.)*hhs.se$/": "hhs.drive.test.sunet.se", - "/@(\\w*\\.)*hig.se$/": "hig.drive.test.sunet.se", - "/@(\\w*\\.)*his.se$/": "his.drive.test.sunet.se", - "/@(\\w*\\.)*hj.se$/": "hj.drive.test.sunet.se", - "/@(\\w*\\.)*hkr.se$/": "hkr.drive.test.sunet.se", - "/@(\\w*\\.)*hv.se$/": "hv.drive.test.sunet.se", - "/@(\\w*\\.)*irf.se$/": "irf.drive.test.sunet.se", - "/@(\\w*\\.)*kb.se$/": "kb.drive.test.sunet.se", - "/@(\\w*\\.)*ki.se$/": "ki.drive.test.sunet.se", - "/@(\\w*\\.)*kkh.se$/": "kkh.drive.test.sunet.se", - "/@(\\w*\\.)*kmh.se$/": "kmh.drive.test.sunet.se", - "/@(\\w*\\.)*konstfack.se$/": "konstfack.drive.test.sunet.se", - "/@(\\w*\\.)*kth.se$/": "kth.drive.test.sunet.se", - "/@(\\w*\\.)*kva.se$/": "kva.drive.test.sunet.se", - "/@(\\w*\\.)*liu.se$/": "liu.drive.test.sunet.se", - "/@(\\w*\\.)*lnu.se$/": "lnu.drive.test.sunet.se", - "/@(\\w*\\.)*ltu.se$/": "ltu.drive.test.sunet.se", - "/@(\\w*\\.)*lu.se$/": "lu.drive.test.sunet.se", - "/@(\\w*\\.)*mah.se$/": "mau.drive.test.sunet.se", - "/@(\\w*\\.)*mau.se$/": "mau.drive.test.sunet.se", - "/@(\\w*\\.)*mdh.se$/": "mdu.drive.test.sunet.se", - "/@(\\w*\\.)*mdu.se$/": "mdu.drive.test.sunet.se", - "/@(\\w*\\.)*miun.se$/": "miun.drive.test.sunet.se", - "/@(\\w*\\.)*nordunet.se$/": "nordunet.drive.test.sunet.se", - "/@(\\w*\\.)*nordu.net$/": "nordunet.drive.test.sunet.se", - "/@(\\w*\\.)*nrm.se$/": "nrm.drive.test.sunet.se", - "/@(\\w*\\.)*oru.se$/": "oru.drive.test.sunet.se", - "/@(\\w*\\.)*rkh.se$/": "rkh.drive.test.sunet.se", - "/@(\\w*\\.)*sics.se$/": "sics.drive.test.sunet.se", - "/@(\\w*\\.)*slu.se$/": "slu.drive.test.sunet.se", - "/@(\\w*\\.)*smhi.se$/": "smhi.drive.test.sunet.se", - "/@(\\w*\\.)*sp.se$/": "sp.drive.test.sunet.se", - "/@(\\w*\\.)*su.se$/": "su.drive.test.sunet.se", - "/@(\\w*\\.)*sunet.se$/": "sunet.drive.test.sunet.se", - "/@(\\w*\\.)*suni.se$/": "suni.drive.test.sunet.se", - "/@(\\w*\\.)*swamid.se$/": "swamid.drive.test.sunet.se", - "/@(\\w*\\.)*ths.se$/": "ths.drive.test.sunet.se", - "/@(\\w*\\.)*uhr.se$/": "uhr.drive.test.sunet.se", - "/@(\\w*\\.)*umu.se$/": "umu.drive.test.sunet.se", - "/@(\\w*\\.)*uniarts.se$/": "uniarts.drive.test.sunet.se", - "/@(\\w*\\.)*uu.se$/": "uu.drive.test.sunet.se", - "/@(\\w*\\.)*vinnova.se$/": "vinnova.drive.test.sunet.se", - "/@(\\w*\\.)*vr.se$/": "vr.drive.test.sunet.se", + "/@(\\w+\\.)*antagning.se$/": "antagning.drive.test.sunet.se", + "/@(\\w+\\.)*bth.se$/": "bth.drive.test.sunet.se", + "/@(\\w+\\.)*chalmers.se$/": "chalmers.drive.test.sunet.se", + "/@(\\w+\\.)*du.se$/": "du.drive.test.sunet.se", + "/@(\\w+\\.)*eduid.se$/": "extern.drive.test.sunet.se", + "/@(\\w+\\.)*esh.se$/": "esh.drive.test.sunet.se", + "/@(\\w+\\.)*fhs.se$/": "fhs.drive.test.sunet.se", + "/@(\\w+\\.)*gih.se$/": "gih.drive.test.sunet.se", + "/@(\\w+\\.)*gu.se$/": "gu.drive.test.sunet.se", + "/@(\\w+\\.)*hb.se$/": "hb.drive.test.sunet.se", + "/@(\\w+\\.)*shh.se$/": "shh.drive.test.sunet.se", + "/@(\\w+\\.)*hh.se$/": "hh.drive.test.sunet.se", + "/@(\\w+\\.)*hhs.se$/": "hhs.drive.test.sunet.se", + "/@(\\w+\\.)*hig.se$/": "hig.drive.test.sunet.se", + "/@(\\w+\\.)*his.se$/": "his.drive.test.sunet.se", + "/@(\\w+\\.)*hj.se$/": "hj.drive.test.sunet.se", + "/@(\\w+\\.)*hkr.se$/": "hkr.drive.test.sunet.se", + "/@(\\w+\\.)*hv.se$/": "hv.drive.test.sunet.se", + "/@(\\w+\\.)*irf.se$/": "irf.drive.test.sunet.se", + "/@(\\w+\\.)*kb.se$/": "kb.drive.test.sunet.se", + "/@(\\w+\\.)*ki.se$/": "ki.drive.test.sunet.se", + "/@(\\w+\\.)*kkh.se$/": "kkh.drive.test.sunet.se", + "/@(\\w+\\.)*kmh.se$/": "kmh.drive.test.sunet.se", + "/@(\\w+\\.)*konstfack.se$/": "konstfack.drive.test.sunet.se", + "/@(\\w+\\.)*kth.se$/": "kth.drive.test.sunet.se", + "/@(\\w+\\.)*kva.se$/": "kva.drive.test.sunet.se", + "/@(\\w+\\.)*liu.se$/": "liu.drive.test.sunet.se", + "/@(\\w+\\.)*lnu.se$/": "lnu.drive.test.sunet.se", + "/@(\\w+\\.)*ltu.se$/": "ltu.drive.test.sunet.se", + "/@(\\w+\\.)*lu.se$/": "lu.drive.test.sunet.se", + "/@(\\w+\\.)*mah.se$/": "mau.drive.test.sunet.se", + "/@(\\w+\\.)*mau.se$/": "mau.drive.test.sunet.se", + "/@(\\w+\\.)*mdh.se$/": "mdu.drive.test.sunet.se", + "/@(\\w+\\.)*mdu.se$/": "mdu.drive.test.sunet.se", + "/@(\\w+\\.)*miun.se$/": "miun.drive.test.sunet.se", + "/@(\\w+\\.)*nordunet.se$/": "nordunet.drive.test.sunet.se", + "/@(\\w+\\.)*nordu.net$/": "nordunet.drive.test.sunet.se", + "/@(\\w+\\.)*nrm.se$/": "nrm.drive.test.sunet.se", + "/@(\\w+\\.)*oru.se$/": "oru.drive.test.sunet.se", + "/@(\\w+\\.)*rkh.se$/": "rkh.drive.test.sunet.se", + "/@(\\w+\\.)*sics.se$/": "sics.drive.test.sunet.se", + "/@(\\w+\\.)*slu.se$/": "slu.drive.test.sunet.se", + "/@(\\w+\\.)*smhi.se$/": "smhi.drive.test.sunet.se", + "/@(\\w+\\.)*sp.se$/": "sp.drive.test.sunet.se", + "/@(\\w+\\.)*su.se$/": "su.drive.test.sunet.se", + "/@(\\w+\\.)*sunet.se$/": "sunet.drive.test.sunet.se", + "/@(\\w+\\.)*suni.se$/": "suni.drive.test.sunet.se", + "/@(\\w+\\.)*swamid.se$/": "swamid.drive.test.sunet.se", + "/@(\\w+\\.)*ths.se$/": "ths.drive.test.sunet.se", + "/@(\\w+\\.)*uhr.se$/": "uhr.drive.test.sunet.se", + "/@(\\w+\\.)*umu.se$/": "umu.drive.test.sunet.se", + "/@(\\w+\\.)*uniarts.se$/": "uniarts.drive.test.sunet.se", + "/@(\\w+\\.)*uu.se$/": "uu.drive.test.sunet.se", + "/@(\\w+\\.)*vinnova.se$/": "vinnova.drive.test.sunet.se", + "/@(\\w+\\.)*vr.se$/": "vr.drive.test.sunet.se", "/$/": "extern.drive.test.sunet.se" } From 5472b767c879545820ebe3cbd810ba3015ef5681 Mon Sep 17 00:00:00 2001 From: Richard Freitag Date: Mon, 9 Oct 2023 11:10:46 +0100 Subject: [PATCH 3/7] Update mappingfile also in production --- .../application/mappingfile-prod.json.erb | 112 +++++++++--------- 1 file changed, 56 insertions(+), 56 deletions(-) diff --git a/templates/application/mappingfile-prod.json.erb b/templates/application/mappingfile-prod.json.erb index b188884..18f0553 100644 --- a/templates/application/mappingfile-prod.json.erb +++ b/templates/application/mappingfile-prod.json.erb @@ -1,58 +1,58 @@ { - "/antagning.se$/": "antagning.drive.sunet.se", - "/bth.se$/": "bth.drive.sunet.se", - "/chalmers.se$/": "chalmers.drive.sunet.se", - "/du.se$/": "du.drive.sunet.se", - "/eduid.se$/": "extern.drive.sunet.se", - "/esh.se$/": "esh.drive.sunet.se", - "/fhs.se$/": "fhs.drive.sunet.se", - "/gih.se$/": "gih.drive.sunet.se", - "/gu.se$/": "gu.drive.sunet.se", - "/hb.se$/": "hb.drive.sunet.se", - "/@shh.se$/": "shh.drive.sunet.se", - "/@hh.se$/": "hh.drive.sunet.se", - "/hhs.se$/": "hhs.drive.sunet.se", - "/hig.se$/": "hig.drive.sunet.se", - "/his.se$/": "his.drive.sunet.se", - "/hj.se$/": "hj.drive.sunet.se", - "/hkr.se$/": "hkr.drive.sunet.se", - "/hv.se$/": "hv.drive.sunet.se", - "/irf.se$/": "irf.drive.sunet.se", - "/kb.se$/": "kb.drive.sunet.se", - "/ki.se$/": "ki.drive.sunet.se", - "/kkh.se$/": "kkh.drive.sunet.se", - "/kmh.se$/": "kmh.drive.sunet.se", - "/konstfack.se$/": "konstfack.drive.sunet.se", - "/kth.se$/": "kth.drive.sunet.se", - "/kva.se$/": "kva.drive.sunet.se", - "/liu.se$/": "liu.drive.sunet.se", - "/lnu.se$/": "lnu.drive.sunet.se", - "/ltu.se$/": "ltu.drive.sunet.se", - "/lu.se$/": "lu.drive.sunet.se", - "/mah.se$/": "mau.drive.sunet.se", - "/mau.se$/": "mau.drive.sunet.se", - "/mdh.se$/": "mdu.drive.sunet.se", - "/mdu.se$/": "mdu.drive.sunet.se", - "/miun.se$/": "miun.drive.sunet.se", - "/nordunet.se$/": "nordunet.drive.sunet.se", - "/nordu.net$/": "nordunet.drive.sunet.se", - "/nrm.se$/": "nrm.drive.sunet.se", - "/oru.se$/": "oru.drive.sunet.se", - "/rkh.se$/": "rkh.drive.sunet.se", - "/sics.se$/": "sics.drive.sunet.se", - "/slu.se$/": "slu.drive.sunet.se", - "/smhi.se$/": "smhi.drive.sunet.se", - "/sp.se$/": "sp.drive.sunet.se", - "/su.se$/": "su.drive.sunet.se", - "/sunet.se$/": "sunet.drive.sunet.se", - "/suni.se$/": "suni.drive.sunet.se", - "/swamid.se$/": "swamid.drive.sunet.se", - "/ths.se$/": "ths.drive.sunet.se", - "/uhr.se$/": "uhr.drive.sunet.se", - "/umu.se$/": "umu.drive.sunet.se", - "/uniarts.se$/": "uniarts.drive.sunet.se", - "/uu.se$/": "uu.drive.sunet.se", - "/vinnova.se$/": "vinnova.drive.sunet.se", - "/vr.se$/": "vr.drive.sunet.se", - "/$/": "extern.drive.sunet.se" + "/@(\\w+\\.)*antagning.se$/": "antagning.drive.test.sunet.se", + "/@(\\w+\\.)*bth.se$/": "bth.drive.test.sunet.se", + "/@(\\w+\\.)*chalmers.se$/": "chalmers.drive.test.sunet.se", + "/@(\\w+\\.)*du.se$/": "du.drive.test.sunet.se", + "/@(\\w+\\.)*eduid.se$/": "extern.drive.test.sunet.se", + "/@(\\w+\\.)*esh.se$/": "esh.drive.test.sunet.se", + "/@(\\w+\\.)*fhs.se$/": "fhs.drive.test.sunet.se", + "/@(\\w+\\.)*gih.se$/": "gih.drive.test.sunet.se", + "/@(\\w+\\.)*gu.se$/": "gu.drive.test.sunet.se", + "/@(\\w+\\.)*hb.se$/": "hb.drive.test.sunet.se", + "/@(\\w+\\.)*shh.se$/": "shh.drive.test.sunet.se", + "/@(\\w+\\.)*hh.se$/": "hh.drive.test.sunet.se", + "/@(\\w+\\.)*hhs.se$/": "hhs.drive.test.sunet.se", + "/@(\\w+\\.)*hig.se$/": "hig.drive.test.sunet.se", + "/@(\\w+\\.)*his.se$/": "his.drive.test.sunet.se", + "/@(\\w+\\.)*hj.se$/": "hj.drive.test.sunet.se", + "/@(\\w+\\.)*hkr.se$/": "hkr.drive.test.sunet.se", + "/@(\\w+\\.)*hv.se$/": "hv.drive.test.sunet.se", + "/@(\\w+\\.)*irf.se$/": "irf.drive.test.sunet.se", + "/@(\\w+\\.)*kb.se$/": "kb.drive.test.sunet.se", + "/@(\\w+\\.)*ki.se$/": "ki.drive.test.sunet.se", + "/@(\\w+\\.)*kkh.se$/": "kkh.drive.test.sunet.se", + "/@(\\w+\\.)*kmh.se$/": "kmh.drive.test.sunet.se", + "/@(\\w+\\.)*konstfack.se$/": "konstfack.drive.test.sunet.se", + "/@(\\w+\\.)*kth.se$/": "kth.drive.test.sunet.se", + "/@(\\w+\\.)*kva.se$/": "kva.drive.test.sunet.se", + "/@(\\w+\\.)*liu.se$/": "liu.drive.test.sunet.se", + "/@(\\w+\\.)*lnu.se$/": "lnu.drive.test.sunet.se", + "/@(\\w+\\.)*ltu.se$/": "ltu.drive.test.sunet.se", + "/@(\\w+\\.)*lu.se$/": "lu.drive.test.sunet.se", + "/@(\\w+\\.)*mah.se$/": "mau.drive.test.sunet.se", + "/@(\\w+\\.)*mau.se$/": "mau.drive.test.sunet.se", + "/@(\\w+\\.)*mdh.se$/": "mdu.drive.test.sunet.se", + "/@(\\w+\\.)*mdu.se$/": "mdu.drive.test.sunet.se", + "/@(\\w+\\.)*miun.se$/": "miun.drive.test.sunet.se", + "/@(\\w+\\.)*nordunet.se$/": "nordunet.drive.test.sunet.se", + "/@(\\w+\\.)*nordu.net$/": "nordunet.drive.test.sunet.se", + "/@(\\w+\\.)*nrm.se$/": "nrm.drive.test.sunet.se", + "/@(\\w+\\.)*oru.se$/": "oru.drive.test.sunet.se", + "/@(\\w+\\.)*rkh.se$/": "rkh.drive.test.sunet.se", + "/@(\\w+\\.)*sics.se$/": "sics.drive.test.sunet.se", + "/@(\\w+\\.)*slu.se$/": "slu.drive.test.sunet.se", + "/@(\\w+\\.)*smhi.se$/": "smhi.drive.test.sunet.se", + "/@(\\w+\\.)*sp.se$/": "sp.drive.test.sunet.se", + "/@(\\w+\\.)*su.se$/": "su.drive.test.sunet.se", + "/@(\\w+\\.)*sunet.se$/": "sunet.drive.test.sunet.se", + "/@(\\w+\\.)*suni.se$/": "suni.drive.test.sunet.se", + "/@(\\w+\\.)*swamid.se$/": "swamid.drive.test.sunet.se", + "/@(\\w+\\.)*ths.se$/": "ths.drive.test.sunet.se", + "/@(\\w+\\.)*uhr.se$/": "uhr.drive.test.sunet.se", + "/@(\\w+\\.)*umu.se$/": "umu.drive.test.sunet.se", + "/@(\\w+\\.)*uniarts.se$/": "uniarts.drive.test.sunet.se", + "/@(\\w+\\.)*uu.se$/": "uu.drive.test.sunet.se", + "/@(\\w+\\.)*vinnova.se$/": "vinnova.drive.test.sunet.se", + "/@(\\w+\\.)*vr.se$/": "vr.drive.test.sunet.se", + "/$/": "extern.drive.test.sunet.se" } From cdf16db30954e8c009d1557fcdd0666a620e4ee6 Mon Sep 17 00:00:00 2001 From: Micke Nordin Date: Tue, 10 Oct 2023 10:33:28 +0200 Subject: [PATCH 4/7] Typo --- manifests/onlyoffice.pp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifests/onlyoffice.pp b/manifests/onlyoffice.pp index cdbf08c..6d63ac0 100644 --- a/manifests/onlyoffice.pp +++ b/manifests/onlyoffice.pp @@ -13,7 +13,7 @@ class sunetdrive::onlyoffice () { $domain = 'drive.test.sunet.se' } exec { 'collabora_docker_login': - cmd => "docker login registry.gitlab.collabora.com -u ${token_name} -p ${access_token}", + command => "docker login registry.gitlab.collabora.com -u ${token_name} -p ${access_token}", } sunet::collabora::docs { 'sunet-onlyoffice': dns => [ '89.32.32.32' ], From 5df8dba25cb438719cfa40a22cb75d156466f9a7 Mon Sep 17 00:00:00 2001 From: Magnus Andersson Date: Thu, 12 Oct 2023 08:59:17 +0200 Subject: [PATCH 5/7] backup-all-buckets: Safeguard backup runs if a backup process on that bucket is already in progress. --- templates/script/backup-all-buckets.erb.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/templates/script/backup-all-buckets.erb.sh b/templates/script/backup-all-buckets.erb.sh index 9ded804..66c909f 100644 --- a/templates/script/backup-all-buckets.erb.sh +++ b/templates/script/backup-all-buckets.erb.sh @@ -36,15 +36,17 @@ function do_backup { local bucket="${3}" local mirrorbucket="${bucket}-mirror" local mountpoint="/opt/backupmounts/${bucket}" + ps aux | grep duplicity | grep "[^a-zA-Z]${bucket}" > /dev/null + local oktorun=$? mkdir -p ${mountpoint} - rclone mount ${project}:${bucket} ${mountpoint}/ --daemon --allow-other --dir-cache-time 24h + [ ${oktorun} -ne 0 ] && rclone mount ${project}:${bucket} ${mountpoint}/ --daemon --allow-other --dir-cache-time 24h rclone mkdir ${mirror}:${mirrorbucket} - duplicity --full-if-older-than 1M --asynchronous-upload --tempdir /mnt --archive-dir /mnt \ + [ ${oktorun} -ne 0 ] && duplicity --full-if-older-than 1M --asynchronous-upload --tempdir /mnt --archive-dir /mnt \ --no-encryption ${mountpoint} rclone://${mirror}:/${mirrorbucket} umount ${mountpoint} rmdir ${mountpoint} # Clean up - duplicity remove-all-but-n-full ${number_of_full_to_keep} --tempdir /mnt --archive-dir /mnt \ + [ ${oktorun} -ne 0 ] && duplicity remove-all-but-n-full ${number_of_full_to_keep} --tempdir /mnt --archive-dir /mnt \ --force rclone://${mirror}:/${mirrorbucket} } From 059bd041e690c320f6191728bc0cbdea99f37acc Mon Sep 17 00:00:00 2001 From: Magnus Andersson Date: Thu, 12 Oct 2023 09:21:57 +0200 Subject: [PATCH 6/7] backup-all-buckets: Add comment about safeguard --- templates/script/backup-all-buckets.erb.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/script/backup-all-buckets.erb.sh b/templates/script/backup-all-buckets.erb.sh index 66c909f..200a5a1 100644 --- a/templates/script/backup-all-buckets.erb.sh +++ b/templates/script/backup-all-buckets.erb.sh @@ -37,7 +37,7 @@ function do_backup { local mirrorbucket="${bucket}-mirror" local mountpoint="/opt/backupmounts/${bucket}" ps aux | grep duplicity | grep "[^a-zA-Z]${bucket}" > /dev/null - local oktorun=$? + local oktorun=$? # 1 == this bucket has no other bakup process in progress mkdir -p ${mountpoint} [ ${oktorun} -ne 0 ] && rclone mount ${project}:${bucket} ${mountpoint}/ --daemon --allow-other --dir-cache-time 24h rclone mkdir ${mirror}:${mirrorbucket} From 1e9164dcd4c7d1cfcb89a098711314fd2895912e Mon Sep 17 00:00:00 2001 From: Micke Nordin Date: Tue, 17 Oct 2023 10:25:33 +0200 Subject: [PATCH 7/7] Nextcloud: Implement logs to stdout --- templates/application/docker-compose_nextcloud.yml.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/application/docker-compose_nextcloud.yml.erb b/templates/application/docker-compose_nextcloud.yml.erb index e6d4468..7e34396 100644 --- a/templates/application/docker-compose_nextcloud.yml.erb +++ b/templates/application/docker-compose_nextcloud.yml.erb @@ -36,7 +36,7 @@ services: - 89.32.32.32 ports: - 443:443 - command: apachectl -D FOREGROUND + command: sh -c 'tail -f /var/www/html/data/nextcloud.log | tee -a /proc/1/fd/2 & apachectl -D FOREGROUND' tty: true networks: