Post Kubernetes Deployment Status To Flowdock
8.7K
Watches for Kubernetes Deployments and posts status updates to one or more Flowdock chat rooms.
Notifications are controlled by adding annotations to Deployments.
pipenv install
pipenv run python k8s-notify.py --config <path-to-config.yml>
k8s-notify is intended to be deployed inside a Kubernetes Cluster.
Example manifests can be found here
See the example-config here
cluster_name: "Kubernetes Cluster"
receivers:
flowdock:
cluster_ops:
token: "{FLOWDOCK_TOKEN_CLUSTER_OPS}"
sre:
token: "{FLOWDOCK_TOKEN_SRE}"
This example defines a flowdock receiver (currently the only type supported), and two teams cluster_ops and sre.
Annotations on the deployment matching the teams will be routed to the flowdock room identified by the injected flowdock-token.
Environment variables are supported in the config (see above example).
Enabling notifications for Deployments is managed through the use of annotations.
apiVersion: apps/v1
kind: Deployment
metadata:
name: nginx
annotations:
app.mintel.com/k8s-notify.enabled: "true"
app.mintel.com/k8s-notify.team: sre
app.mintel.com/k8s-notify.receiver: flowdock
app.mintel.com/k8s-notify.vcs-url: https://vcs-url
app.mintel.com/k8s-notify.public-url: https://public-facing-url
app.mintel.com/k8s-notify.logs-url: https://logs-url
app.mintel.com/k8s-notify.monitoring-url: https://monitoring-url
app.mintel.com/k8s-notify.health-status-url: https://heatlh-status-url
The -url annotations are optional. If specified, they will be included in the notification.
Content type
Image
Digest
Size
77.2 MB
Last updated
over 5 years ago
docker pull mintel/k8s-notify