moved data
This commit is contained in:
parent
55d9a9e9f9
commit
71b0b70bee
|
@ -8,17 +8,17 @@ in
|
|||
environment.systemPackages = [
|
||||
nextcloud
|
||||
];
|
||||
systemd.timers."nextcloud-backup" = {
|
||||
systemd.timers."nextcloud-db-backup" = {
|
||||
wantedBy = [ "timers.target" ];
|
||||
timerConfig = {
|
||||
# OnBootSec = "5m";
|
||||
# OnUnitActiveSec = "5m";
|
||||
OnCalendar="*-*-* 2:00:00";
|
||||
Unit = "nextcloud-backup.service";
|
||||
Unit = "nextcloud-db-backup.service";
|
||||
};
|
||||
};
|
||||
|
||||
systemd.services."nextcloud-backup" = {
|
||||
systemd.services."nextcloud-db-backup" = {
|
||||
script = with pkgs; ''
|
||||
set -eu
|
||||
${postgresql}/bin/pg_dump "nextcloud" | ${openssh}/bin/ssh -i /etc/nixos/.secrets/tulpan Glenn@nas "cat - > back/nextcloud/latest.sql"
|
||||
|
@ -28,8 +28,16 @@ in
|
|||
User = "postgres";
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
services = {
|
||||
# restic = {
|
||||
# "nextcloud-repo" = {
|
||||
# passwordFile = "/etc/nixos/.secrets/restic_pw";
|
||||
# };
|
||||
# };
|
||||
|
||||
|
||||
nginx.virtualHosts = {
|
||||
${domain} = {
|
||||
forceSSL = true;
|
||||
|
@ -48,6 +56,8 @@ in
|
|||
# Let NixOS install and configure the database automatically.
|
||||
database.createLocally = true;
|
||||
# Increase the maximum file upload size.
|
||||
datadir="/pool/var/lib/nextcloud";
|
||||
|
||||
maxUploadSize = "16G";
|
||||
https = true;
|
||||
autoUpdateApps.enable = true;
|
||||
|
|
Loading…
Reference in a new issue