Source
yaml
id: outputs-from-shell-commands
namespace: company.team
tasks:
- id: process
type: io.kestra.plugin.scripts.shell.Commands
commands:
- echo '::{"outputs":{"test":"value","int":2,"bool":true,"float":3.65}}::'
- id: return
type: io.kestra.plugin.core.debug.Return
format: "{{ outputs.process.vars.test }}"
About this blueprint
Software Engineering Outputs
This blueprint shows how to expose custom outputs from a shell script.
The ::{"outputs":{"test":"value"}}::
allow to expose your data in task output. Those outputs are accessible through the {{ outputs.<taskid>.vars.<your_output> }}
command in other tasks.
More Related Blueprints