Actions190
- Auth Actions
- Backup Actions
- Custom Templates Actions
- Docker Actions
- Edge Groups Actions
- Edge Jobs Actions
- Edge Stacks Actions
- Endpoint Groups Actions
- Endpoints Actions
- Endpoint Delete Batch
- Endpoint List
- Endpoint Create
- Endpoint Delete
- Endpoint Inspect
- Endpoint Update
- Endpoint Association Delete
- Endpoint Dockerhub Status
- Endpoint Edge Status Inspect
- Endpoint Force Update Service
- Endpoint Registries List
- Endpoint Registry Access
- Endpoint Settings Update
- Endpoint Snapshot
- Endpoint Update Relations
- Gitops Actions
- Helm Actions
- Intel Actions
- Kubernetes Actions
- Get All Kubernetes Applications
- Get All Kubernetes Applications Count
- Delete Cluster Role Bindings
- Delete Cluster Roles
- Get All Kubernetes Cluster Role Bindings
- Get All Kubernetes Cluster Roles
- Get All Kubernetes Config Maps
- Get All Kubernetes Config Maps Count
- Get Kubernetes Cron Jobs
- Delete Cron Jobs
- Get Kubernetes Dashboard
- Get All Kubernetes Ingress Controllers
- Update Kubernetes Ingress Controllers
- Get All Kubernetes Cluster Ingresses
- Get All Kubernetes Cluster Ingresses Count
- Delete Kubernetes Ingresses
- Get Kubernetes Jobs
- Delete Jobs
- Get Kubernetes Max Resource Limits
- Get Applications Resources
- Get Kubernetes Metrics For All Nodes
- Get Kubernetes Metrics For Node
- Get Kubernetes Metrics For All Pods
- Get Kubernetes Metrics For Pod
- Delete Kubernetes Namespace
- Get Kubernetes Namespaces
- Create Kubernetes Namespace
- Update Kubernetes Namespace Deprecated
- Get Kubernetes Namespace
- Update Kubernetes Namespace
- Get Kubernetes Config Map
- Get Kubernetes Ingress Controllers By Namespace
- Update Kubernetes Ingress Controllers By Namespace
- Get All Kubernetes Ingresses
- Create Kubernetes Ingress
- Update Kubernetes Ingress
- Get Kubernetes Ingress
- Get Kubernetes Secret
- Get Kubernetes Services By Namespace
- Create Kubernetes Service
- Update Kubernetes Service
- Kubernetes Namespaces Toggle System
- Get Kubernetes Volumes In Namespace
- Get Kubernetes Namespaces Count
- Get Kubernetes Nodes Limits
- Get Kubernetes RBAC Status
- Delete Role Bindings
- Get Kubernetes Role Bindings
- Get Kubernetes Roles
- Delete Roles
- Get Kubernetes Secrets
- Get Kubernetes Secrets Count
- Delete Service Accounts
- Get Kubernetes Service Accounts
- Get Kubernetes Services
- Get All Kubernetes Services Count
- Delete Kubernetes Services
- Get All Kubernetes Volumes
- Get Kubernetes Volume
- Get All Kubernetes Volumes Count
- Get Kubernetes Config
- Ldap Actions
- Registries Actions
- Resource Controls Actions
- Settings Actions
- Ssl Actions
- Stacks Actions
- Stack List
- Stack Delete
- Stack Inspect
- Stack Update
- Stack Associate
- Stack File Inspect
- Stack Update Git
- Stack Git Redeploy
- Stack Migrate
- Stack Start
- Stack Stop
- Stack Create Kubernetes Git
- Stack Create Kubernetes File
- Stack Create Kubernetes Url
- Stack Create Docker Standalone File
- Stack Create Docker Standalone Repository
- Stack Create Docker Standalone String
- Stack Create Docker Swarm File
- Stack Create Docker Swarm Repository
- Stack Create Docker Swarm String
- Stack Delete Kubernetes By Name
- Webhook Invoke
- Tags Actions
- Team Memberships Actions
- Teams Actions
- Templates Actions
- Upload Actions
- Users Actions
Edge Stacks → Edge Stack Create File
AI-generatedOverview
This node operation allows you to create a new Edge Stack file in Portainer, a container management platform. An Edge Stack is a deployment configuration that can be pushed to one or more edge groups (clusters of edge devices). This operation is useful for automating the deployment of containerized applications or services to distributed edge environments.
Typical use cases include:
- Deploying Docker Compose or Kubernetes manifests to edge devices managed by Portainer.
- Automating updates and rollouts of container stacks across multiple edge groups.
- Managing container registries and deployment options programmatically.
For example, you might use this node to deploy a new version of a microservice stack defined in a Docker Compose file to all your edge clusters with a single workflow.
Properties
| Name | Meaning |
|---|---|
| Name | Name of the stack. Must start with a letter or number and contain only lowercase alphanumeric characters, hyphens, or underscores. |
| File | Content of the stack file (e.g., Docker Compose YAML or Kubernetes manifest) |
| Edge Groups | JSON stringified array of Edge Group IDs where the stack will be deployed |
| Deployment Type | Deployment type: 0 for 'compose' stacks, 1 for 'kubernetes' stacks |
| Registries | JSON stringified array of Registry IDs to use for this stack |
| Use Manifest Namespaces | Boolean flag indicating whether to use namespaces defined in the manifest instead of the default namespace (relevant for Kubernetes deployments) |
| Pre Pull Image | Boolean flag to pre-pull container images before deployment |
| Retry Deploy | Boolean flag to retry deployment if it fails |
| Additional Fields | Collection of optional additional parameters; currently supports: |
| - Dryrun | If true, validates settings without creating the stack (non-persistent check) |
Output
The node outputs JSON data representing the created Edge Stack object as returned by the Portainer API. This typically includes details such as the stack ID, name, deployment status, associated edge groups, and other metadata.
No binary data output is expected from this operation.
Dependencies
- Requires an active connection to a Portainer instance via its API.
- Needs an API authentication token or key configured in n8n credentials to authorize requests.
- The Portainer API base URL must be set correctly in the credentials.
- The node uses the Portainer API endpoint
/apito send the stack creation request.
Troubleshooting
- Invalid Stack Name: Ensure the stack name follows the naming rules (lowercase alphanumeric, hyphens, underscores, starting with letter/number). Violations may cause API errors.
- Malformed JSON Strings: The
Edge GroupsandRegistriesproperties require JSON stringified arrays. Invalid JSON will cause request failures. - Authentication Errors: Verify that the API key/token and base URL are correct and have sufficient permissions.
- Deployment Type Mismatch: Using the wrong deployment type (compose vs kubernetes) for the stack file content may cause deployment errors.
- Dryrun Misuse: Setting dryrun to true will not create the stack but only validate inputs; ensure this is intended.
- Network Issues: Connectivity problems to the Portainer server will prevent stack creation.
Common error messages usually come from the Portainer API and relate to validation failures, unauthorized access, or malformed requests. Checking the API response message and verifying input formats usually resolves these issues.