Skip to content

Commit be726a0

Browse files
committed
fixup! dynamodb: add sharedDb option
1 parent a0e6c73 commit be726a0

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

src/modules/services/dynamodb-local.nix

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ let
1414
cd "${baseDir}"
1515
1616
extraFlags=""
17-
if [[ "${toString cfg.sharedDb}" == "true" ]]; then
18-
extraFlags="-sharedDb"
17+
if [[ "${toString cfg.sharedDb}" ]]; then
18+
extraFlags+="-sharedDb"
1919
fi
2020
2121
${config.services.dynamodb-local.package}/bin/dynamodb-local -port ${toString cfg.port} -dbPath ${baseDir} -disableTelemetry $extraFlags
@@ -40,7 +40,11 @@ in
4040
sharedDb = lib.mkOption {
4141
type = types.bool;
4242
default = false;
43-
description = "If true, enables the -sharedDb flag for DynamoDB Local.";
43+
description = ''
44+
If true, enables the -sharedDb flag for DynamoDB Local.
45+
When enabled, DynamoDB Local creates a single database file named shared-local-instance.db.
46+
Every program that connects to DynamoDB accesses this file. If you delete the file, you lose any data stored in it.
47+
'';
4448
};
4549
};
4650

0 commit comments

Comments
 (0)