New to Kestra?
Use blueprints to kickstart your first workflows.
Build a weekly inventory of every Terragrunt output with Kestra. run-all output -json is parsed by Python and summarized into a Slack digest.
Terraform outputs are the public interface of every unit, endpoints, connection strings, resource ids, yet most teams only see them one folder at a time, moments after an apply. This blueprint builds a living inventory of what every environment exposes: terragrunt run-all output -json captures the outputs of every unit in the estate into a single file, a Python task parses and counts them, and Slack receives a weekly digest listing every output name. The raw JSON stays attached to the execution as an artifact, so the digest is a headline and the artifact is the record.
The demo estate ships inline through inputFiles with two units whose modules expose two outputs each, and the task applies them first so outputs exist, no cloud credentials required.
collect_outputs (io.kestra.plugin.terragrunt.cli.TerragruntCLI) materializes the repo, runs terragrunt run-all apply --non-interactive --working-dir live so the demo units have state, then captures terragrunt run-all output -json --working-dir live into inventory.json, exported through outputFiles.summarize_inventory (io.kestra.plugin.scripts.python.Script on the Process task runner) reads the file with a lenient raw_decode loop, because run-all output emits one JSON document per unit, and counts documents and output values.{{ outputs.summarize_inventory.vars.* }}.post_digest posts the summary to Slack, and the errors block escalates a broken run to Discord, the digest is routine, a missing inventory is an incident.Collecting outputs by hand means running commands in N folders and pasting results into a document that is stale by Friday. Kestra runs the collection on a schedule, stores every snapshot as an execution artifact, turns the counts into structured outputs other flows can consume, and routes the result to the people who need it. The inventory becomes a pipeline product instead of a chore.
env from {{ secret('...') }}.SLACK_WEBHOOK_URL: Slack incoming webhook URL.DISCORD_WEBHOOK_URL: Discord incoming webhook URL.SLACK_WEBHOOK_URL and DISCORD_WEBHOOK_URL secrets to your Kestra namespace.disabled: false on the weekly trigger.inputFiles with namespaceFiles or a Git clone so the inventory reflects your real estate.inventory.json against the previous execution's artifact and alert on removed outputs.tofu and the TERRAGRUNT_TFPATH environment variable in the task env.