Live contexts
This page describes the contexts a live workflow can use in expressions for calculating YAML attribute values.
Live Contexts
Context name | Description |
---|---|
| Contains environment variables set in a workflow or a job. For more information, see |
| Information about the main workflow settings, defaults, etc. See |
| Information about the project. See |
| Contains a mapping of images on the Apolo registry. See |
| Multi-job context. For more information, see |
| A mapping of global workflow parameters. For more information, see |
| A set of job tags set in a workflow or a job. See |
| Contains a mapping of volume definitions. For more information, see |
| A mapping of the flow's workspace to a git repository. For more information, see |
env
context
env
contextThe env
context contains environment variables that have been set in a workflow or a job. For more information about setting environment variables in your workflow, see "Live workflow syntax."
The env
context syntax allows you to use the value of an environment variable in your workflow file. If you want to use the value of an environment variable inside a job, use your operating system's standard method for reading environment variables.
Property name | Type | Description |
---|---|---|
|
| The value of a specific environment variable. |
flow
context
flow
contextThe flow
context contains information about the workflow: its id, title, etc.
Property name | Type | Description |
---|---|---|
|
| The workflow's ID. It's automatically generated based on the workflow's YAML filename with a dropped suffix (this will always |
|
| The project's ID. It is automatically generated based on the name of the flow folder. You can override it using |
|
| A path to the workspace (the root folder of the flow). |
|
| The workflow title. Set the |
project
context
project
contextThe project
context contains information about the project: its ID, owner, etc.
Property name | Type | Description |
---|---|---|
|
| The project's ID. It is automatically generated based on the name of the flow folder. You can override it using |
|
| The project's owner. See also: the project configuration. |
|
| The platform project name. Set the project.project_name attribute to override the auto-calculated value. |
images
context
images
contextContains information about images defined in the images
section of a live workflow.
Property name | Type | Description |
---|---|---|
|
| The image definition identifier. For more information, see |
|
| The image reference. For more information, see |
|
| The context directory used for building the image or For more information, see |
|
| The absolute path, pointing to the |
|
| A path to For more information, see |
|
| Full version of the |
|
| A sequence of additional build arguments. For more information, see |
|
| Environment variables passed to the image builder. For more information, see |
|
| A sequence of volume definitions passed to the image builder. For more information, see |
multi
context
multi
contextThe additional arguments passed to multi-job.
Property name | Type | Description |
---|---|---|
|
| Additional command line arguments passed to multi-job.
The command line run defines the field as
|
|
| multi-job suffix added to |
params
context
params
contextParameter described in the jobs.<job-id>.params
attribute and available for substitution - for example, in jobs.<job-id>.cmd
calculation.
Property name | Type | Description |
---|---|---|
|
| The value of a specific parameter. |
Supported parameter values: project
, flow
, env
, tags
, volumes
, images
.
tags
context
tags
contextA set of job tags.
Tags are combined from system tags (project:<project-id>
, job:<job-id>
), flow default tags (see defaults.tags
attribute), and job-specific tags (see jobs.<job-id>.tags
attribute).
Property name | Type | Description |
---|---|---|
|
| This context changes for each job. You can access this context from any job. |
volumes
context
volumes
contextContains information about volumes defined in the volumes
section of a live workflow.
Property name | Type | Description |
---|---|---|
|
| The volume definition identifier. For more information, see |
|
| Remote volume URI, e.g. |
|
| The path inside a job by which the volume should be mounted. For more information, see |
|
|
For more information, see |
|
| A path in the workspace folder to synchronize with remote Apolo storage or For more information, see |
|
| Full version of |
|
| A volume reference that can be used as a The value is assembled from |
|
| Like |
|
| Like |
git
context
git
contextThe git
context contains a mapping of your flow's workspace to a git repository.
This context can only be used if the flow's workspace is inside some git repository.
Property name | Type | Description |
---|---|---|
|
| SHA of the current commit. |
|
| Name of the current branch. |
|
| List of tags that point to the current commit. |
Last updated