<p>How to get slack notification while any k8s pod status changed? can't use kube bots as it's not allowed in my organisation.</p>

Niladri Dey
<p>You can use &quot;Alertmanager&quot; from the Prometheus stack for such notifications.
Once you have the prometheus stack up and running, you can configure custom alerts based on any property of objects in kubernetes and forward them to slack</p>
<p><a href="https://github.com/coreos/prometheus-operator/blob/master/Documentation/user-guides/alerting.md" rel="nofollow noreferrer">https://github.com/coreos/prometheus-operator/blob/master/Documentation/user-guides/alerting.md</a></p>
<p><strong>Updated:</strong></p>
<p>In case you can't deploy any external tool, you could right a simple shell script which gets pod status via <code>kubectl</code></p>
<p>Something like:</p>
<pre><code>kubectl get pods mypod -ojson | jq .status.phase
</code></pre>
<p>You can poll on this command and use the slack <a href="https://api.slack.com/messaging/webhooks" rel="nofollow noreferrer">webhooks</a> to send a notification when it changes value</p>
