strong-plumber-41198
01/04/2024, 10:42 AMaverage-finland-92144
01/11/2024, 10:24 PMworkflow_notifications:
enabled: true
config:
notifications:
type: slack
slack:
url: <slack-webhook-url>
In this example, replace <slack-webhook-url>
with your Slack Webhook URL.
2. Specify the notifications in your launch plan (example for workflow executions):
from flytekit import Slack, WorkflowExecutionPhase, LaunchPlan, workflow, task
@task
def my_task():
...
@workflow
def my_workflow():
my_task()
my_launch_plan = LaunchPlan.get_or_create(
workflow=my_workflow,
notifications=[
Slack(
phases=[WorkflowExecutionPhase.SUCCEEDED, WorkflowExecutionPhase.FAILED],
recipients_email=["my-channel@slack.com"],
)
],
)
In this example, a Slack notification will be sent to <mailto:my-channel@slack.com|my-channel@slack.com>
when the workflow execution succeeds or fails.
Please note that the recipients_email
parameter is used to specify the Slack channel or user to send the notification to. The value should be in the format <channel-or-user>@slack.com
.strong-plumber-41198
01/12/2024, 8:23 AMstrong-plumber-41198
01/12/2024, 12:40 PMflyte-poc-notifications
• added the webhook url to the values.yaml
file and ran tf apply
• I’ve tried a launch plan using <mailto:flyte-poc-notifications@slack.com|flyte-poc-notifications@slack.com>
, <mailto:Jake@slack.com|Jake@slack.com>
, <member_id>@slack.com
, as well as creating an email for the channel and trying that, but received no notification from the workflow.average-finland-92144
01/15/2024, 2:35 PM