Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion flows/copy-flows-to-new-tenant.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ tasks:

pluginDefaults:
- type: io.kestra.plugin.core.http
forced: true
values:
retry:
type: constant
Expand Down
14 changes: 5 additions & 9 deletions flows/create-hubspot-ticket-on-failure.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ namespace: system
tasks:
- id: create_ticket
type: io.kestra.plugin.hubspot.tickets.Create
apiKey: my_api_key
apiKey: "{{ secret('HUBSPOT_API_KEY') }}"
subject: Workflow failed
content: "{{ trigger.executionId }} has failed on {{ taskrun.startDate }}"
stage: 3
Expand All @@ -13,14 +13,10 @@ tasks:
triggers:
- id: on_failure
type: io.kestra.plugin.core.trigger.Flow
conditions:
- type: io.kestra.plugin.core.condition.ExecutionStatus
in:
- FAILED
- WARNING
- type: io.kestra.plugin.core.condition.ExecutionNamespace
namespace: company
comparison: PREFIX
states:
- FAILED
- WARNING
when: "{{ flow.namespace | startsWith('company') }}"

extend:
shortDescription: "This system blueprint implements an incident management and customer support integration pattern by automatically creating HubSpot tickets whenever a Kestra."
Expand Down
14 changes: 5 additions & 9 deletions flows/create-linear-issue-on-failure.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ namespace: system
tasks:
- id: linear
type: io.kestra.plugin.linear.issues.Create
token: your_api_token
token: "{{ secret('LINEAR_API_TOKEN') }}"
team: MyTeamName
title: Workflow failed
description: "{{ trigger.executionId }} has failed on {{ taskrun.startDate }}.
Expand All @@ -16,14 +16,10 @@ tasks:
triggers:
- id: on_failure
type: io.kestra.plugin.core.trigger.Flow
conditions:
- type: io.kestra.plugin.core.condition.ExecutionStatus
in:
- FAILED
- WARNING
- type: io.kestra.plugin.core.condition.ExecutionNamespace
namespace: company
comparison: PREFIX
states:
- FAILED
- WARNING
when: "{{ flow.namespace | startsWith('company') }}"

extend:
shortDescription: "This system blueprint implements an incident management and monitoring pattern by automatically creating Linear issues whenever a Kestra workflow execution."
Expand Down
8 changes: 3 additions & 5 deletions flows/failure-alert-discord.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,9 @@ tasks:
triggers:
- id: on_failure
type: io.kestra.plugin.core.trigger.Flow
conditions:
- type: io.kestra.plugin.core.condition.ExecutionStatus
in:
- FAILED
- WARNING
states:
- FAILED
- WARNING

extend:
shortDescription: "This system flow will help you set up alerts for failed workflow executions. Using this pattern, you can manage alerts on failure in one place."
Expand Down
10 changes: 4 additions & 6 deletions flows/failure-alert-email.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ tasks:
type: io.kestra.plugin.email.MailSend
from: alerts@example.com
to: team@company.com
username: username@example.com
username: "{{ secret('EMAIL_USERNAME') }}"
password: "{{ secret('EMAIL_PASSWORD') }}"
host: smtp.com
port: 465
Expand All @@ -16,11 +16,9 @@ tasks:
triggers:
- id: on_failure
type: io.kestra.plugin.core.trigger.Flow
conditions:
- type: io.kestra.plugin.core.condition.ExecutionStatus
in:
- FAILED
- WARNING
states:
- FAILED
- WARNING

extend:
shortDescription: "This system flow will help you set up alerts for failed workflow executions. Using this pattern, you can manage alerts on failure in one place."
Expand Down
8 changes: 3 additions & 5 deletions flows/failure-alert-gmail.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,9 @@ tasks:
triggers:
- id: on_failure
type: io.kestra.plugin.core.trigger.Flow
conditions:
- type: io.kestra.plugin.core.condition.ExecutionStatus
in:
- FAILED
- WARNING
states:
- FAILED
- WARNING

extend:
shortDescription: "This system flow will help you set up alerts for failed workflow executions. Using this pattern, you can manage alerts on failure in one place."
Expand Down
8 changes: 3 additions & 5 deletions flows/failure-alert-sentry-1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,9 @@ tasks:
triggers:
- id: on_failure
type: io.kestra.plugin.core.trigger.Flow
conditions:
- type: io.kestra.plugin.core.condition.ExecutionStatus
in:
- FAILED
- WARNING
states:
- FAILED
- WARNING

extend:
shortDescription: "This system flow will help you set up alerts for failed workflow executions. Using this pattern, you can manage alerts on failure in one place."
Expand Down
12 changes: 4 additions & 8 deletions flows/failure-alert-sentry.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,10 @@ tasks:
triggers:
- id: failed_prod_workflows
type: io.kestra.plugin.core.trigger.Flow
conditions:
- type: io.kestra.plugin.core.condition.ExecutionStatus
in:
- FAILED
- WARNING
- type: io.kestra.plugin.core.condition.ExecutionNamespace
namespace: company
prefix: true
states:
- FAILED
- WARNING
when: "{{ flow.namespace | startsWith('company') }}"

extend:
shortDescription: "This flow shows how to send an alert to Sentry when a flow fails."
Expand Down
8 changes: 3 additions & 5 deletions flows/failure-alert-slack.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,9 @@ tasks:
triggers:
- id: on_failure
type: io.kestra.plugin.core.trigger.Flow
conditions:
- type: io.kestra.plugin.core.condition.ExecutionStatus
in:
- FAILED
- WARNING
states:
- FAILED
- WARNING

extend:
shortDescription: "This system flow will help you set up alerts for failed workflow executions. Using this pattern, you can manage alerts on failure in one place."
Expand Down
8 changes: 3 additions & 5 deletions flows/failure-alert-teams.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,9 @@ tasks:
triggers:
- id: on_failure
type: io.kestra.plugin.core.trigger.Flow
conditions:
- type: io.kestra.plugin.core.condition.ExecutionStatus
in:
- FAILED
- WARNING
states:
- FAILED
- WARNING

extend:
shortDescription: "This system flow will help you set up alerts for failed workflow executions. Using this pattern, you can manage alerts on failure in one place."
Expand Down
8 changes: 3 additions & 5 deletions flows/failure-alert-zenduty.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,9 @@ tasks:
triggers:
- id: on_failure
type: io.kestra.plugin.core.trigger.Flow
conditions:
- type: io.kestra.plugin.core.condition.ExecutionStatus
in:
- FAILED
- WARNING
states:
- FAILED
- WARNING

extend:
shortDescription: "This system flow will help you set up alerts for failed workflow executions. Using this pattern, you can manage alerts on failure in one place."
Expand Down
5 changes: 2 additions & 3 deletions flows/k8s-namespace-logs-and-events.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ tasks:
pod_names: "{{ outputs.get_pods.metadataItems | jq('[.[].name]') }}"

- id: fetch_logs_per_pod
type: io.kestra.plugin.core.flow.ForEach
type: io.kestra.plugin.core.flow.Loop
description: Loop over pods
values: "{{ outputs.extract_pod_names.values.pod_names | first }}"
concurrencyLimit: 5
Expand Down Expand Up @@ -68,8 +68,7 @@ tasks:
--server={{ secret('masterUrl') }}

pluginDefaults:
- forced: true
type: io.kestra.plugin.scripts.shell.Commands
- type: io.kestra.plugin.scripts.shell.Commands
values:
containerImage: bitnami/kubectl
taskRunner: # only for local testing with minikube
Expand Down
4 changes: 3 additions & 1 deletion flows/kv-store-purge.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@ tasks:
- id: purge_kv
type: io.kestra.plugin.core.kv.PurgeKV
description: Remove key-value (KV) entries from Kestra’s internal storage every day at 12AM.
expiredOnly: true
behavior:
type: key
expiredOnly: true # Delete only keys whose expiration date is in the past.
namespaces:
- system
- company
Expand Down
4 changes: 2 additions & 2 deletions flows/push-to-git.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ tasks:
includeChildNamespaces: true
gitDirectory: _flows
url: https://github.com/kestra-io/scripts
username: git_username
username: "{{ secret('GITHUB_USERNAME') }}"
password: "{{ secret('GITHUB_ACCESS_TOKEN') }}"
branch: kestra
commitMessage: add flows {{ now() }}
Expand All @@ -22,7 +22,7 @@ tasks:
files: "*"
gitDirectory: _files
url: https://github.com/kestra-io/scripts
username: git_username
username: "{{ secret('GITHUB_USERNAME') }}"
password: "{{ secret('GITHUB_ACCESS_TOKEN') }}"
branch: dev
commitMessage: add namespace files {{ now() }}
Expand Down
4 changes: 2 additions & 2 deletions flows/sync-from-git.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ tasks:
delete: true
url: https://github.com/kestra-io/flows
branch: main
username: git_username
username: "{{ secret('GITHUB_USERNAME') }}"
password: "{{ secret('GITHUB_ACCESS_TOKEN') }}"
dryRun: true

Expand All @@ -21,7 +21,7 @@ tasks:
delete: true
url: https://github.com/kestra-io/flows
branch: main
username: git_username
username: "{{ secret('GITHUB_USERNAME') }}"
password: "{{ secret('GITHUB_ACCESS_TOKEN') }}"
dryRun: true

Expand Down
12 changes: 4 additions & 8 deletions flows/zenduty-failure-alert.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,10 @@ tasks:
triggers:
- id: failed_prod_workflows
type: io.kestra.plugin.core.trigger.Flow
conditions:
- type: io.kestra.plugin.core.condition.ExecutionStatus
in:
- FAILED
- WARNING
- type: io.kestra.plugin.core.condition.ExecutionNamespace
namespace: company
prefix: true
states:
- FAILED
- WARNING
when: "{{ flow.namespace | startsWith('company') }}"

extend:
shortDescription: "This flow sends an alert to Zenduty when a production flow fails. The only required input is an integration key string value."
Expand Down
Loading