Portainer icon

Portainer

Trabalhe com dados da API do Portainer para gerenciar Docker

Overview

This node integrates with the Portainer API to manage Docker containers and other Docker-related resources. Specifically, the Container - Unpause operation allows you to unpause a paused Docker container within a specified environment (endpoint) managed by Portainer.

Use cases include:

  • Resuming a container that was previously paused for maintenance or resource management.
  • Automating container lifecycle management workflows where containers are paused and resumed based on external triggers or schedules.
  • Integrating container state control into broader automation pipelines.

Example: You have a container paused during off-hours to save resources and want to automatically unpause it at the start of the workday.

Properties

Name Meaning
Environment ID The ID of the Portainer environment/endpoint where the container is running.
Container ID The unique identifier of the Docker container to be unpaused.

Output

The node outputs the JSON response from the Portainer API after attempting to unpause the container. This typically includes status information about the container or confirmation of the action.

No binary data output is involved in this operation.

Dependencies

  • Requires an active connection to a Portainer instance with API access.
  • Needs an API key credential configured in n8n to authenticate requests to the Portainer API.
  • The Portainer environment ID must correspond to a valid endpoint configured in Portainer.
  • The container ID must refer to an existing container within the specified environment.

Troubleshooting

  • Invalid Environment ID or Container ID: If the IDs are incorrect or do not exist, the API will return an error. Verify the IDs in Portainer before running the node.
  • Authentication Errors: Ensure the API key credential is valid and has sufficient permissions to perform container operations.
  • Container Not Paused: Attempting to unpause a container that is not currently paused may result in an error or no effect. Confirm container state before unpausing.
  • Network Issues: Connectivity problems between n8n and the Portainer server can cause request failures. Check network accessibility and firewall settings.

Common error messages usually come directly from the Portainer API and indicate issues such as unauthorized access, resource not found, or invalid operation.

Links and References

Discussion