Skip to content

Commit 4f13405

Browse files
Add MERGE_STRATEGY environment variable (#240)
Co-authored-by: Quetzalli <hola@quetzalliwrites.com>
1 parent 929d043 commit 4f13405

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

src/content/docs/aws/capabilities/config/configuration.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -414,6 +414,7 @@ To learn more about these configuration options, see [Cloud Pods](/aws/capabilit
414414
| `POD_LOAD_CLI_TIMEOUT` | 60 (default) | Timeout in seconds to wait before returning from load operations on the Cloud Pods CLI |
415415
| `POD_ENCRYPTION` | `0` (default) \| `1` | Whether to encrypt the Cloud Pods artifacts at rest. |
416416
| `ENABLE_POD_RESOURCES=1` | `0` (default) \| `1` | Whether to save a detailed Stack Overview including available resources for the Cloud Pod |
417+
| `MERGE_STRATEGY` | `account-region-merge` (default) \| `service-merge` \| `overwrite` | The merge strategy to apply when loading a Cloud Pod into LocalStack (see [state merging](/aws/capabilities/state-management/cloud-pods/#state-merging)) |
417418

418419
## Extensions
419420

src/content/docs/aws/capabilities/state-management/cloud-pods.mdx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -589,9 +589,12 @@ The available strategies are:
589589
- `service-merge`: This strategy merges services at the account-region level, provided there's no overlap in resources.
590590
It prioritizes the loaded resources when merging.
591591

592+
The LocalStack's default merge strategy can be changed via the `MERGE_STRATEGY` [configuration variable](/aws/capabilities/config/configuration/).
593+
592594
### LocalStack CLI
593595

594-
To activate merge strategies, set `--strategy <strategy>` when loading a Cloud Pod using the LocalStack CLI.
596+
Every `pod load` operation uses the merge strategy set in `MERGE_STRATEGY` (`account-region-merge` by default).
597+
When loading a Cloud Pod via the LocalStack CLI, set the `--strategy <strategy>` option to override the strategy in the configuration variable.
595598
For instance, to load a Cloud Pod named `test-pod-s3-sqs` with the `service-merge` strategy, run the following command:
596599

597600
```bash

0 commit comments

Comments
 (0)