diff --git a/modules/nixos/services/nextcloud/default.nix b/modules/nixos/services/nextcloud/default.nix index dd23c61..07850f7 100644 --- a/modules/nixos/services/nextcloud/default.nix +++ b/modules/nixos/services/nextcloud/default.nix @@ -5,16 +5,6 @@ ... }: let cfg = config.aa.services.nextcloud; - secrets = config.age.secrets; - - mkNextcloudSecret = attrs: { - name = attrs.name; - value = { - file = attrs.path; - owner = "nextcloud"; - group = "nextcloud"; - }; - }; in { options.aa.services.nextcloud = with lib; { enable = mkEnableOption "nextcloud"; @@ -29,24 +19,11 @@ in { }; config = lib.mkIf cfg.enable { - age.secrets = builtins.listToAttrs (builtins.map (attrs: mkNextcloudSecret attrs) [ - { - name = "restic/password"; - path = ../../../../secrets/nextcloud_restic_password.age; - } - { - name = "restic/env"; - path = ../../../../secrets/nextcloud_restic_env.age; - } - { - name = "restic/repo"; - path = ../../../../secrets/nextcloud_restic_repo.age; - } - { - name = "nextcloud_admin"; - path = ../../../../secrets/nextcloud_admin.age; - } - ]); + age.secrets.nextcloud_admin = { + file = ../../../../secrets/nextcloud_admin.age; + owner = "nextcloud"; + group = "nextcloud"; + }; services.nextcloud = { enable = true; @@ -70,7 +47,7 @@ in { config = { dbtype = "pgsql"; adminuser = "alejandro"; - adminpassFile = secrets.nextcloud_admin.path; + adminpassFile = config.age.secrets.nextcloud_admin.path; }; }; @@ -80,23 +57,6 @@ in { useACMEHost = cfg.acmeCertName; }; - services.restic.backups = { - nextcloud = { - user = "nextcloud"; - initialize = true; - paths = [config.services.nextcloud.datadir]; - environmentFile = secrets."restic/env".path; - repositoryFile = secrets."restic/repo".path; - passwordFile = secrets."restic/password".path; - timerConfig = { - OnCalendar = "00:05"; - Persistent = true; - RandomizedDelaySec = "5h"; - }; - pruneOpts = ["--keep-daily 7" "--keep-weekly 5" "--keep-monthly 12" "--keep-yearly 9001"]; - }; - }; - networking.firewall.allowedTCPPorts = [80 443]; }; } diff --git a/packages/teslamate-grafana-dashboards/default.nix b/packages/teslamate-grafana-dashboards/default.nix index c0b1c87..8645d5e 100644 --- a/packages/teslamate-grafana-dashboards/default.nix +++ b/packages/teslamate-grafana-dashboards/default.nix @@ -5,13 +5,13 @@ }: stdenv.mkDerivation rec { pname = "teslamate-grafana-dashboards"; - version = "1.32.0"; + version = "1.31.0"; src = fetchFromGitHub { owner = "teslamate-org"; repo = "teslamate"; rev = "v${version}"; - hash = "sha256-diQRtJYfzGIVLxrdBad3XKWCtR97rj9Q1ZJ9MmvJGRk="; + hash = "sha256-aX6FjOKyjsA/0IgLw/AnB01ddNk0yS6vd01BH/reBP4="; }; dontBuild = true; diff --git a/secrets/nextcloud_restic_env.age b/secrets/nextcloud_restic_env.age deleted file mode 100644 index e19d4e9..0000000 Binary files a/secrets/nextcloud_restic_env.age and /dev/null differ diff --git a/secrets/nextcloud_restic_password.age b/secrets/nextcloud_restic_password.age deleted file mode 100644 index 8c46824..0000000 --- a/secrets/nextcloud_restic_password.age +++ /dev/null @@ -1,7 +0,0 @@ -age-encryption.org/v1 --> piv-p256 UIEGzg AtUSDrnOeV44xXzVmduHJgpJEzozc+LqdLKlkiiDdJXA -cJWbnIZGvISxhNXa6Jpiw8NrEfCncMAQHfW8v5uzzvE --> ssh-ed25519 Yk7ehg OwDJrMxpMvaxDnGBaSr8+WjGy44DAYwcPo7qujD8zCQ -7LjtdWBG9+n89+NWvWLX/E63se9okelHkEb2HxFAkU8 ---- 7f/WYFPS9vxFsRa6MNX6EAbGya42EsVxrZbCTEhuIOc -P O < c[&!W*ogJo,  P@ؔ7 %"rʽ=ckc #P@lƗXi"c庀GmN/jWjku:x(.>%ߑ#~͞v/kbFg3Q \ No newline at end of file diff --git a/secrets/nextcloud_restic_repo.age b/secrets/nextcloud_restic_repo.age deleted file mode 100644 index 875f289..0000000 --- a/secrets/nextcloud_restic_repo.age +++ /dev/null @@ -1,8 +0,0 @@ -age-encryption.org/v1 --> piv-p256 UIEGzg AowX1qo/8GwbPcZGt2yW77S7rA8/xtDGUocmR3hmQpTO -vNy0dR5fwAk+2fV7xhEQq9Ja4VRW5RaDHo9a3L1FZhk --> ssh-ed25519 Yk7ehg IUjXb3+yVVIY3aa5wTagrRdm3bL9fGfCCfc20roqh1g -D+aX+TYMg21CCfpVj6DQVcaRbU4sN5tB0aC0R6TfBFw ---- u2cH5LG8E5DBRkL8FGq3s1I2Ht5Lhlk9hKrSaOjtISQ -=q(=vc~i(PaGGx! I<&N7JA.'e -DHLtt 1JFL(9Ek[Q;ł?/ʤnP \ No newline at end of file diff --git a/secrets/secrets.nix b/secrets/secrets.nix index e63a709..4d53ec0 100644 --- a/secrets/secrets.nix +++ b/secrets/secrets.nix @@ -15,9 +15,6 @@ in { "hass_mqtt.age".publicKeys = [users.me machines.pi4 machines.node machines.gospel]; "hydra-aws-creds.age".publicKeys = [users.me machines.gospel]; "nextcloud_admin.age".publicKeys = [users.me machines.node machines.gospel]; - "nextcloud_restic_env.age".publicKeys = [users.me machines.node]; - "nextcloud_restic_password.age".publicKeys = [users.me machines.node]; - "nextcloud_restic_repo.age".publicKeys = [users.me machines.node]; "tailscale_git_server.age".publicKeys = [users.me machines.git]; # This key expires, might have to update "teslamate_db.age".publicKeys = [users.me machines.node machines.gospel]; "teslamate_encryption.age".publicKeys = [users.me machines.node machines.gospel];