Commit 1c22b64f authored by nikstur's avatar nikstur
Browse files

nixos/tests/nextcloud: replace activationScript

Replace with a seprate systemd service
parent af87c194
Loading
Loading
Loading
Loading
+6 −4
Original line number Diff line number Diff line
@@ -13,10 +13,12 @@ in {
    # The only thing the client needs to do is download a file.
    client = { ... }: {
      services.davfs2.enable = true;
      system.activationScripts.davfs2-secrets = ''
        echo "http://nextcloud/remote.php/dav/files/${adminuser} ${adminuser} ${adminpass}" > /tmp/davfs2-secrets
        chmod 600 /tmp/davfs2-secrets
      '';
      systemd.tmpfiles.settings.nextcloud = {
        "/tmp/davfs2-secrets"."f+" = {
          mode = "0600";
          argument = "http://nextcloud/remote.php/dav/files/${adminuser} ${adminuser} ${adminpass}";
        };
      };
      virtualisation.fileSystems = {
        "/mnt/dav" = {
          device = "http://nextcloud/remote.php/dav/files/${adminuser}";