YAML for Run Docker container

Run commands inside a Docker container.

YAML parameters for Run Docker container

PARAMETERS
inline_commandsrequiredstring
The commands to execute inside the Docker container.
docker_image_namerequiredstring
The name of the Docker image.
docker_image_tagrequiredstring
The tag of the Docker image.
typerequiredstring

Value: RUN_DOCKER_CONTAINER

actionrequiredstring
Unique identifier for the action within the pipeline.
integrationstring
Docker registry integration for authentication.
entrypointstring
The entrypoint to use for the Docker container.
regionstring
Cloud region for the Docker registry.
working_directorystring
The directory in which the pipeline filesystem will be mounted.
mount_filesystem_disableboolean
If set to true, the filesystem will not be mounted in the container.
volume_mappingsstring[]
The path preceding the colon is the filesystem path (the folder from the filesystem to be mounted in the container). The path after the colon is the container path (the path in the container, where this filesystem will be located).
run_as_userstring
All build commands are run as the default user defined in the selected Docker image. Can be set to another username (on the condition that this user exists in the selected image).
export_container_pathstring
The path in the container to export.
image_locationstring enum
The location of the image used by the action.
Allowed enum:
PUBLIC_REGISTRY,
PRIVATE_REGISTRY,
ACTION,
ARTIFACT_REGISTRY
docker_registrystring enum
The type of registry from which the image is retrieved.
Allowed enum:
NONE,
DOCKER_HUB,
AMAZON_ECR,
GOOGLE_GCR,
GOOGLE_ARTIFACT_REGISTRY,
OTHER,
GIT_HUB_CONTAINER_REGISTRY,
ARTIFACT_REGISTRY,
DIGITAL_OCEAN_CONTAINER_REGISTRY
use_image_from_actionboolean
If set to true, the image from another action will be used.
docker_build_action_namestring
The name of the action from which the Docker image will be used.
registrystring
The URL of the Docker registry.
loginstring
The username for the Docker registry.
passwordstring
The password for the Docker registry.
trigger_timestring enum
Specifies when the action should be executed.
Allowed enum:
ON_EVERY_EXECUTION,
ON_SUCCESS,
ON_FAILURE,
ON_BACK_TO_SUCCESS,
ON_WARNING,
ON_WAIT_FOR_APPROVE,
ON_TERMINATE
loopstring[]
The list of variables for dynamic action execution. The action runs once for each value.
run_only_on_first_failureboolean
Defines whether the action should be executed on each failure. Restricted to and required if the trigger_time is ON_FAILURE.
disabledboolean
When set to true the action is disabled. By default it is set to false.
timeoutinteger
The timeout in seconds.
ignore_errorsboolean
If set to true the execution will proceed, mark action as a warning and jump to the next action. Doesn't apply to deployment actions.
retry_intervalinteger
Delay time between auto retries in seconds.
retry_countinteger
Number of retries if the action fails.
run_nextstring enum
Defines whether the action should run in parallel with the next one.
Allowed enum:
WAIT_ON_SUCCESS,
IN_SOFT_PARALLEL,
IN_HARD_PARALLEL
trigger_conditionsTriggerConditionYaml[]
The list of trigger conditions to meet so that the action can be triggered.
variablesVariableYaml[]
The list of variables you can use in the action.

Last modified on Apr 27, 2026

YAML examples for Run Docker container

Run Docker container with commands

yaml
- action: "Run container" type: "RUN_DOCKER_CONTAINER" docker_image_name: "library/ubuntu" docker_image_tag: "latest" volume_mappings: - "/:/buddy/mount/directory" inline_commands: "ls -al > ls.log" mount_filesystem_disable: false working_directory: "/buddy/my-repo-dir" export_container_path: "/exportPath" entrypoint: "/bin/sh" variables: - key: "ftp_login" value: "userLogin123" description: "The name of user to FTP." - key: "ftp_password" value: "secure!14ivLMxPgv7TX6c9+ITX/g==" encrypted: true description: "The password for ftp."

Using private image from Docker Hub

yaml
- action: "Run container" type: "RUN_DOCKER_CONTAINER" docker_image_name: "buddyworks/private_image" docker_image_tag: "latest" image_location: "PRIVATE_REGISTRY" docker_registry: "DOCKER_HUB" inline_commands: "ls -al > ls.log" mount_filesystem_disable: false working_directory: "/buddy/my-repo-dir" integration: "my_integration" run_as_user: "${user}" export_container_path: "/exportPath" entrypoint: "/bin/sh" variables: - key: "user" value: "notRoot" - key: "top_secret_password" value: "secure!14ivLMxPgv7TX6c9+ITX/g==" encrypted: true

Using image from private registry

yaml
- action: "Run container" type: "RUN_DOCKER_CONTAINER" docker_image_name: "buddyworks/private_image" docker_image_tag: "latest" image_location: "PRIVATE_REGISTRY" docker_registry: "OTHER" entrypoint: "/bin/sh" volume_mappings: - "/:/buddy/mount/directory" inline_commands: "ls -al > ls.log" mount_filesystem_disable: false working_directory: "/buddy/my-repo-dir" login: "buddyworks" password: "${top_secret_password}" registry: "my.registry.com"

Using image from Google Container Registry

yaml
- action: "Run container" type: "RUN_DOCKER_CONTAINER" docker_image_name: "tokyo-house-147623/private_image" docker_image_tag: "latest" image_location: "PRIVATE_REGISTRY" docker_registry: "GOOGLE_GCR" volume_mappings: - "/:/buddy/mount/directory" inline_commands: "ls -al > ls.log" mount_filesystem_disable: false working_directory: "/buddy/my-repo-dir" export_container_path: "/exportPath" entrypoint: "/bin/sh" registry: "my.gcr.com" integration: "my_integration"

Using image from Amazon ECR

yaml
- action: "Run container" type: "RUN_DOCKER_CONTAINER" docker_image_name: "private_image" docker_image_tag: "latest" image_location: "PRIVATE_REGISTRY" docker_registry: "AMAZON_ECR" entrypoint: "/bin/sh" volume_mappings: - "/:/buddy/mount/directory" inline_commands: "ls -al > ls.log" mount_filesystem_disable: false working_directory: "/buddy/my-repo-dir" region: "us-east-1" integration: "my_integration"

Using image built in previous action

yaml
- action: "Run Docker Container" type: "RUN_DOCKER_CONTAINER" image_location: "ACTION" inline_commands: "ls -al > ls.log"

Minimal Docker container run

yaml
- action: "Run container" type: "RUN_DOCKER_CONTAINER" docker_image_name: "library/alpine" docker_image_tag: "latest" inline_commands: "echo 'Hello World'"