Export Variables

During the deploy workflow, a mechanism exists, through which the Components can export environment variables from within the runner container, so they can be used in other subsequent Components.

The exportVariables attribute of the Component lists the environment variables which will be captured and have their values stored. This happens at the end of the stage, after all scripts from the deploy attribute finished executing.

You can use the exported variable as follows:

{{ components.{COMPONENT_NAME}.exported.{VARIABLE_NAME} }}

Example:

{{ components.mysql-runner.exported.MYSQL_HOST }}

πŸ“˜

The Components are ran in sequence when deploying or starting the Environment, and in parallel when stopping or destroying.
You can find out more in the dedicated Environment Workflows section.

🚧

Exported values are only captured during Deploy, and overridden after every successful deployment.