Container Stack Management
Overview
A Container Stack is a Docker Compose-based application definition stored in WEDA Core. It represents a multi-container workload — one or more services defined in a Docker Compose file — that can be deployed to any number of WEDA Nodes.
Every change to a Container Stack produces a new revision: an immutable, versioned snapshot of its Compose content, environment values, and description. Revisions accumulate over time, allowing you to:
- Deploy specific versions to different device groups
- Compare any two revisions (field-level diff)
- Roll back by redeploying an older revision
Active deployments are not affected when you update a stack — devices continue running their deployed revision until explicitly redeployed.
WEDA supports Docker Compose format only. Helm Chart format is not supported.
Operations
Stack Configuration
| Operation | API | Description |
|---|---|---|
| Create Stack | POST /api/v1/orgs/{orgId}/stack-configs | Create a new Container Stack (creates revision 1 automatically) |
| List Stacks | GET /api/v1/orgs/{orgId}/stack-configs | List all Container Stacks in an Org |
| Get Stack | GET /api/v1/orgs/{orgId}/stack-configs/{stackConfigId} | Get the latest configuration of a stack |
| Update Stack | PATCH /api/v1/orgs/{orgId}/stack-configs/{stackConfigId} | Update the compose file (creates a new revision automatically) |
| Delete Stack | DELETE /api/v1/orgs/{orgId}/stack-configs/{stackConfigId} | Delete a stack and all its revisions |
Revision Management
| Operation | API | Description |
|---|---|---|
| List Revisions | GET /api/v1/orgs/{orgId}/stack-configs/{stackConfigId}/revisions | List all revisions of a stack |
| Get Revision | GET /api/v1/orgs/{orgId}/stack-configs/{stackConfigId}/revisions/{stackRevisionId} | Get details of a specific revision |
| Compare Revisions | GET /api/v1/orgs/{orgId}/stack-configs/revisions/diff?sourceStackRevisionId={id1}&targetStackRevisionId={id2} | Field-level diff between any two revisions |
| Delete Revision | DELETE /api/v1/orgs/{orgId}/stack-configs/{stackConfigId}/revisions/{stackRevisionId} | Delete a specific revision |
Constraints
stackNameis required and must be unique within the OrgstackNamehas a maximum length of 63 characters and may contain only lowercase letters, digits, and hyphens (-)stackNamemust start and end with a letter or digit and cannot contain consecutive hyphens (--)typemust becomposecomposeFileContentmust be base64-encoded valid Docker Compose YAMLenvironmentis optional and provides values that the Compose file can reference using${VARIABLE_NAME}descriptionis optional and has a maximum length of 1024 characters- Updating a stack does not affect devices running an older revision — they must be explicitly redeployed
- A revision cannot be deleted while it is associated with an existing deployment. Undeploy it from all devices before deleting the revision
Examples of Stack names:
- Valid:
factory-monitor-01 - Invalid:
Factory_Monitor(uppercase letters and underscores are not allowed) - Invalid:
factory--monitor(consecutive hyphens are not allowed) - Invalid:
-factory-monitor(a name cannot start with a hyphen)
Scenario
A developer creates a monitoring stack and updates it to add a sidecar service:
Related
- Set up registry credentials before referencing private images in your compose file: Registry Management
- Deploy a stack revision to devices and control running containers: Container Deployment & Commands