Add Zoom alert provider - #1349
Conversation
|
@xchose Looks good, but to merge this we need manual testing with a real Zoom account, with screenshots, etc. |
|
Manual testing done with a real Zoom account (free tier, Team Chat enabled). ✅ Setup
MethodRan a temporary Go test (in Result in Zoom Team ChatHead = involved object, sub head = severity, body = event message, fields = event metadata, as described in the PR: Error pathAlso verified error handling against the real API: after revoking the webhook connection (
|
Sorry to be a pain here @xchose, but AI tends to do this kind of shallow testing. We need an e2e manual test. To accept new providers here in notification-controller, we normally ask contributors to: create a kind cluster in your computer, install Flux inside, update notification-controller with an image built from this PR, update the CRD with the changes from this PR as well, and we need to see an e2e test of the feature with screenshots. |
My testing at KIND cluster (in docker):➜ ~ kind get clusters
flux-zoom-e2e
➜ ~ kubectl cluster-info --context kind-flux-zoom-e2e
Kubernetes control plane is running at https://127.0.0.1:55575
CoreDNS is running at https://127.0.0.1:55575/api/v1/namespaces/kube-system/services/kube-dns:dns/proxy
To further debug and diagnose cluster problems, use 'kubectl cluster-info dump'.
➜ ~ kubectl get nodes -o wide
NAME STATUS ROLES AGE VERSION INTERNAL-IP EXTERNAL-IP OS-IMAGE KERNEL-VERSION CONTAINER-RUNTIME
flux-zoom-e2e-control-plane Ready control-plane 7m38s v1.36.1 172.18.0.2 <none> Debian GNU/Linux 13 (trixie) 6.12.76-linuxkit (arm64) containerd://2.3.1
notification-controller runs the image built from this PR➜ ~ kubectl -n flux-system get deploy notification-controller -o jsonpath='{.spec.template.spec.containers[0].image}'
test/notification-controller:zoom-e2e
➜ ~ kubectl -n flux-system get pods
NAME READY STATUS RESTARTS AGE
helm-controller-5f98857c49-twftc 1/1 Running 0 2m53s
kustomize-controller-5c867fd7bd-v5pg9 1/1 Running 0 2m53s
notification-controller-649bc89b74-k2vv7 1/1 Running 0 103s
source-controller-854fd9756d-25sbl 1/1 Running 0 2m53sBuilt with CRD from this PR accepts
|
|
@xchose can you please rebase with upstream main and force push. |
Add the zoom Provider type for Zoom Team Chat. Events are posted to the Incoming Webhook chatbot endpoint using the rich full-format payload, with the verification token sent in the Authorization header. Assisted-by: Claude Code/claude-fable-5 Signed-off-by: Chose Carreras <xchose@gmail.com>


Fixes #434
Adds a
zoomProvider type for sending Flux alerts to Zoom Team Chat via the Incoming Webhook chatbot. The generic provider cannot be used for this because Zoom expects a specific JSON payload shape.Implementation
fullmessage format: the involved object (kind/name.namespace) as the head, severity as sub head, the event message as body text, and event metadata as key/value fields.format=fullis appended to the webhook URL unless the user already pinned aformatquery parameter.token) is sent raw in theAuthorizationheader, per Zoom's Incoming Webhook docs.postMessageclient.Sample rendered payload:
{ "content": { "head": { "text": "gitrepository/webapp.gitops-system", "sub_head": { "text": "info" } }, "body": [ { "type": "message", "text": "Fetched revision: main@sha1:..." }, { "type": "fields", "items": [ { "key": "revision", "value": "main@sha1:..." } ] } ] } }Testing
internal/notifier/zoom_test.go: asserts payload structure,Authorizationheader,format=fullquery param, format preservation, and constructor validation against anhttptestserver.make test(envtest suite) passes;make generate manifests api-docs tidy fmt vetleave a clean tree.🤖 Generated with Claude Code