Portainer icon

Portainer

Interact with Portainer via API

Actions190

Kubernetes → Get Applications Resources

AI-generated

Overview

This node interacts with a Kubernetes environment to retrieve application resources running on a specific node. It is useful for scenarios where you need to monitor, audit, or manage the applications deployed within a Kubernetes cluster by querying resources tied to a particular node.

For example, if you want to get all the applications running on a given Kubernetes node to check their status or resource usage, this node operation will provide that information.

Properties

Name Meaning
Id Environment (Endpoint) identifier: A numeric ID representing the Kubernetes environment or endpoint to query. This identifies which Kubernetes cluster or environment the request targets.
Node Node name: The name of the Kubernetes node whose application resources you want to retrieve.

Output

The output contains JSON data representing the application resources found on the specified Kubernetes node within the selected environment. This typically includes details about each application such as its metadata, status, and configuration as provided by the Kubernetes API.

If the node supports binary data output, it would represent any associated files or artifacts related to the applications, but based on the provided code and properties, the primary output is structured JSON data describing the resources.

Dependencies

  • Requires access to a Kubernetes environment identified by the provided environment ID.
  • Needs an API key or authentication token configured in n8n credentials to authenticate requests against the Kubernetes API or the intermediary service managing Kubernetes interactions.
  • The node uses HTTP requests with query parameters to fetch data from the Kubernetes API or a proxy service.

Troubleshooting

  • Invalid Environment ID: If the environment ID does not correspond to a valid Kubernetes endpoint, the node will fail to retrieve data. Verify the environment ID is correct and the endpoint is accessible.
  • Incorrect Node Name: Providing a non-existent or misspelled node name will result in empty or error responses. Ensure the node name matches exactly what is registered in the Kubernetes cluster.
  • Authentication Errors: Missing or invalid API credentials will cause authorization failures. Confirm that the API key or token is correctly set up in n8n credentials.
  • Network Issues: Connectivity problems between n8n and the Kubernetes API endpoint can cause timeouts or errors. Check network configurations and firewall rules.
  • API Changes: If the Kubernetes API or the intermediary service changes its schema or endpoints, the node might stop working until updated accordingly.

Links and References

Discussion