You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: add base-path support for running behind reverse proxy (#515)
Add --base-path CLI option and BASE_PATH env variable to allow deploying
behind a reverse proxy (e.g., nginx). All routes use an Express Router
mounted at the base path. All views updated to use basePath for links,
assets, fetch URLs, and breadcrumb navigation. Fix mismatched quotes in
EJS templates and add missing build step in Dockerfile.
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: README.md
+23-1Lines changed: 23 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -18,9 +18,10 @@ Options:
18
18
-`--port PORT` / `-p PORT` - Port to run on (default: 8001)
19
19
-`--host HOST` / `-h HOST` - Host to run on (default: localhost)
20
20
-`--dynamo-endpoint` - DynamoDB endpoint to connect to (default: http://localhost:8000).
21
+
-`--base-path` - Base path for the application (e.g., /dynamo). Useful when running behind a reverse proxy (default: empty).
21
22
-`--skip-default-credentials` - Skip setting default credentials and region. By default the accessKeyId/secretAccessKey are set to "key" and "secret" and the region is set to "us-east-1". If you specify this argument then you need to ensure that credentials are provided some other way. See https://docs.aws.amazon.com/sdk-for-javascript/v3/developer-guide/setting-credentials-node.html for more details on how default credentials provider works.
22
23
23
-
Environment variables `HOST`, `PORT` and `DYNAMO_ENDPOINT` can also be used to set the respective options.
24
+
Environment variables `HOST`, `PORT`, `BASE_PATH` and `DYNAMO_ENDPOINT` can also be used to set the respective options.
24
25
25
26
If you use a local dynamodb that cares about credentials, you can configure them by using the following environment variables `AWS_REGION``AWS_ACCESS_KEY_ID``AWS_SECRET_ACCESS_KEY` or specify the `--skip-default-credentials` argument and rely on the default AWS SDK credentials resolving behavior.
26
27
@@ -33,6 +34,27 @@ If you are accessing your database from another piece of software, the `AWS_ACCE
33
34
34
35
By default `dynamodb-admin` sets a default key/secret to values "key" and "secret" and the region to "us-east-1".
35
36
37
+
### Running behind a reverse proxy
38
+
39
+
When running behind a reverse proxy like nginx, you can use the `--base-path` option to specify a custom base path:
help: 'Skip setting default credentials and region. By default the accessKeyId/secretAccessKey are set to "key" and "secret" and the region is set to "us-east-1". If you specify this argument then you need to ensure that credentials are provided some other way. See https://docs.aws.amazon.com/sdk-for-javascript/v3/developer-guide/setting-credentials-node.html for more details on how default credentials provider works.',
0 commit comments