Day 3 with Workflows — Variable assignment and expressions
Now that we have multiple steps in our workflow definition, let’s see how we can pass data around, from a step to another.
In a step, you can assign values to variables.
Those values can be ints, doubles, strings, or booleans (and also null).
Use the assign
keyword as follows:
- assignments:
assign:
- two: 2
- pi: 3.14
- message: "Hello"
- bool: True
Those variables are available in the whole scope of the workflow, and can be accessed in other steps. So let’s see how we can do something with those variables. Let’s add a second step to our workflow definition:
Read more...