YAML for Cypress

Run Cypress end-to-end tests in a Docker container.

YAML parameters for Cypress

PARAMETERS
execute_commandsrequiredstring[]
The commands that will be executed.
docker_image_namerequiredstring
The name of the Docker image.
typerequiredstring

Value: CYPRESS

actionrequiredstring
Unique identifier for the action within the pipeline.
working_directorystring
The directory in which the pipeline filesystem will be mounted.
setup_commandsstring[]
The command that will be executed only on the first run.
cached_dirsstring[]
The dependencies and directories to be cached and available to every execution in this pipeline.
shellstring enum
The name of the shell that will be used to execute commands.
Allowed enum:
SH,
BASH,
POWERSHELL
execute_every_commandboolean
If set to true all commands will be executed regardless of the result of the previous command.
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).
main_service_namestring
The hostname of the container in which the action is run. The container will be available under this name in the docker network for services.
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).
entrypointstring
The entrypoint to use for the Docker container.
reset_entrypointboolean
If set to true, resets the default entrypoint set by the image.
cache_base_imageboolean
If set to true, the cached version of the image is used, instead of being pulled each time.
ignore_image_pull_failuresboolean
If set to true, use cached image on timeouts (only for official images).
export_container_pathstring
The path in the container to export.
docker_image_tagstring
The tag of the Docker image.
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
artifactstring
The identifier of the artifact from artifact registry.
versionstring
The version of the artifact from artifact 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.
insecure_registryboolean
If set to true, the registry will be accessed over HTTP instead of HTTPS.
target_stagestring
The target stage of the Dockerfile.
do_not_prune_imagesboolean
If set to true, images will not be pruned after the build.
loginstring
The username for the Docker registry.
passwordstring
The password for the Docker registry.
servicesServiceYaml[]
The list of services attached to the build environment.
targetsobject[]
The list of target servers or clusters.
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 Jul 31, 2025

YAML examples for Cypress

Run Cypress E2E tests

yaml
- action: "Run Cypress tests" type: "CYPRESS" trigger_time: "ON_EVERY_EXECUTION" docker_image_name: "cypress/included" docker_image_tag: "latest" execute_commands: - "npm install" - "npx cypress run"