fast-pizza-24629
11/24/2023, 4:27 PMargowf
and argoevents
in an argo
namespace, and I also have event-bus
, and event-source
in another namespace called metaflow
where my workflows/pods run. Everything looks good until here. If I add @trigger(name="test_trigger_join_artifacts")
to my flows and then create the workflow template the sensor
and the sensor-pod
are created. However, when I use ArgoEvent(name="my_trigger").publish()
the workflow is not triggered .
I then tried port-forwarding the event-source
pod and use `urllib.reques`t to trigger the event/workflow (as in the ArgoEvents.publish
method) and the workflow is successfully triggered and executed, I have used this:
data = {"name": "test_trigger_join_artifacts", 'payload': {'name': 'test_trigger_join_artifacts'}}
requests = urllib.request.Request(
"<http://localhost:12000/metaflow-event>",
method="POST",
headers={"Content-Type": "application/json"},
data=json.dumps(data).encode("utf-8")
)
urllib.request.urlopen(requests, timeout=10.0)
my .metaflowconfig
variables look like this:
"METAFLOW_KUBERNETES_NAMESPACE": "metaflow",
"METAFLOW_KUBERNETES_SERVICE_ACCOUNT": "metaflow",
"METAFLOW_SERVICE_INTERNAL_URL": "<http://metaflow-service:8080>",
"METAFLOW_SERVICE_URL": "<https://metaflow-service.ai.veo.co>",
"METAFLOW_SERVICE_HEADERS": "{\"Authorization\": something",
"METAFLOW_ARGO_EVENTS_EVENT":"metaflow-event",
"METAFLOW_ARGO_EVENTS_EVENT_BUS":"default",
"METAFLOW_ARGO_EVENTS_EVENT_SOURCE":"argo-events-webhook",
"METAFLOW_ARGO_EVENTS_SERVICE_ACCOUNT":"operate-workflow-sa",
"METAFLOW_ARGO_EVENTS_WEBHOOK_URL": "<http://argo-events-webhook-eventsource-svc.metaflow:12000/metaflow-event>"
I have the feeling that I need to add an ingress to the event-source
?? I am not sure if I am missing something else? any advice? if the ingress is needed, do you have an example for it?