Docker icon

Docker

Interact with Docker

Actions15

Overview

This node interacts with Docker to perform various operations, specifically focusing on running Docker containers when the 'Run' operation is selected under the 'Network' resource. It pulls a specified Docker image and runs a container with a given command array, capturing the container's standard output and error streams. This node is useful for automating Docker container execution within workflows, such as running network-related Docker containers with custom commands for testing or deployment purposes.

Use Case Examples

  1. Running a network-related Docker container with a specific image and command to automate network tests.
  2. Pulling and executing a Docker image that sets up a network environment for integration testing.

Properties

Name Meaning
Image The Docker image to pull and run for the container.
Command The command to execute inside the Docker container, provided as a JSON array.

Output

JSON

  • stdout - Standard output from the Docker container run command.
  • stderr - Standard error output from the Docker container run command.

Dependencies

  • Docker API accessed via dockerode library
  • Requires Docker API credentials for authentication

Troubleshooting

  • Ensure the 'Command' property is a valid JSON array; otherwise, the node throws an error 'Command must be an array!'.
  • Verify Docker credentials are correctly configured; missing credentials cause 'No credentials got returned!' error.
  • Docker image must be accessible and pullable; network or permission issues may cause failures during image pull.
  • Check Docker daemon is running and accessible from the environment where the node executes.

Discussion