Skip to content

Commit 3094514

Browse files
author
Dr Serge
committed
nextcloud: direct pre-signed download link
1 parent 7c320aa commit 3094514

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

nixos/modules/services/web-apps/nextcloud.nix

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -214,6 +214,7 @@ let
214214
'use_ssl' => ${lib.boolToString s3.useSsl},
215215
${lib.optionalString (s3.region != null) "'region' => '${s3.region}',"}
216216
'use_path_style' => ${lib.boolToString s3.usePathStyle},
217+
'use_presigned_url' => ${lib.boolToString s3.usePresignedUrl},
217218
${lib.optionalString (s3.sseCKeyFile != null) "'sse_c_key' => nix_read_secret('s3_sse_c_key'),"}
218219
],
219220
]
@@ -765,6 +766,15 @@ in
765766
`http://hostname.domain/bucket` instead.
766767
'';
767768
};
769+
usePresignedUrl = lib.mkOption {
770+
type = lib.types.bool;
771+
default = false;
772+
description = ''
773+
Allow bypassing nextcloud instance and serve files
774+
directly from the S3 server. Such a download is protected
775+
with a presigned download link.
776+
'';
777+
};
768778
sseCKeyFile = lib.mkOption {
769779
type = lib.types.nullOr lib.types.path;
770780
default = null;

0 commit comments

Comments
 (0)