Slack Integration with FluxCD for Real-Time Kubernetes Deployment Notifications
In this blog, we will mainly discuss how Slack can be integrated into our Kubernetes cluster deployment process.
Slack Integration with FluxCD for Real-Time Kubernetes Deployment Notifications
In this blog, we will mainly discuss how Slack can be integrated into our Kubernetes cluster deployment process.
As we already know, whenever we make updates or changes to our application, those changes are committed and pushed to the GitHub repository. Most of the time, various issues or errors can occur during the deployment process. Although these problems can be identified through log files, the challenge is that log files are often very lengthy, difficult to read, and make it hard to pinpoint the exact issue.
Slack provides a powerful solution to reduce these difficulties.
When a user makes any update to the application or modifies any part of the cluster, Slack can display whether the deployment has errors or whether the output is correct clearly and instantly. This helps developers quickly understand the status of their deployment without digging through complex log files.

First, you need to create your own Slack account and log in. After logging in, create a new workspace named “K8-notifications.”

After that, we need to create a Slack app to continue our process. Open your web browser, go to https://api.slack.com/apps, and create a new app.

Click the Create App button and select “From scratch.” Then enter a name for your app and choose your workspace to create the application.
Next, go to your Slack account and create a new channel. Give the channel any name you prefer and set its visibility to Public.

After that, go to the Slack API dashboard and select the Install App option to install your Slack app into the workspace. However, Slack will not allow the installation at this point.
The reason is that we must first define the required permissions for the app. These permissions determine what the app is allowed to do and what actions are restricted within the workspace.
Add the following permissions under Bot Token Scopes:
- channels:read
- chat:write
- chat:write.cutomize

These permissions are saved automatically. After adding them, refresh the Install App page. You will now see the Install button appear. Click this button to complete the installation process.
Once the installation is finished, go to your Slack workspace. Type the @ symbol and select the channel you created earlier to ensure the Slack app is properly added to the channel.

Click the Add Them button to add the channel to your workspace. Next, go to your Slack app settings and copy the Auth Token as well.

To authenticate our Slack workspace with the Kubernetes cluster, we need to store the Slack OAuth Token securely inside the cluster. Previously, we authenticated GitHub and ACR using Kubernetes secrets. In this step, we follow the same process creating a secret containing the Slack OAuth Token inside the flux-system namespace.
Open your VS Code terminal, navigate to the flux-system folder, and create the secret using the following command:
kubectl create secret genaric slack-secret --from-literal=token=<your OAuth Tokens> \
--dry-run=client -o yaml > secret.yaml
Retrieving the public certificate
Now, retrieve the public certificate with kubeseal utility.
kubeseal --controller-name=sealed-secrets-controller --controller-namespace=sealed-secrets --fetch-cert > pub.crt
Now that we have the public key, we can encrypt our secret.yaml
kubeseal -o yaml --scope cluster-wide --cert pub.crt < secret.yaml > secret-enc.yaml
After executing this command, you will see a new file named secret-enc.yaml . This file contains the fully encrypted password.
After that, open the kustomization.yaml file inside the same folder and include a new entry that references the Sealed Secrets file.
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- gotk-components.yaml
- gotk-sync.yaml
- helmrepositories/cert-manager.yaml
- helmrepositories/sealed-secrets.yaml
- imagerepositories/lms-static-canary.yaml
- imagepolicies/lms-static-canary.yaml
- image-update-automation.yaml
- acr-secret-enc.yaml
Then, commit and push the changes to the GitHub repository. After that, reconcile the cluster using the flux reconcile command.
flux reconcile source git -n flux-system flux-system
You can view all the details of the secret by using the following command:
kubectl get secret <secret-name> -n flux-system

Then, create two more files inside the flux-system folder:
- notification-alert-slack.yaml
- notification-provider-slack.yaml
notification-alert-slack.yaml
apiVersion: notification.toolkit.fluxcd.io/v1beta3
kind: Alert
metadata:
name: notification-alert-slack
namespace: flux-system
spec:
eventSeverity: info
eventSources:
- kind: Kustomization
name: '*'
- kind: GitRepository
name: '*'
- kind: HelmChart
name: '*'
- kind: HelmRepository
name: '*'
- kind: HelmRelease
name: '*'
- kind: ImageRepository
name: '*'
- kind: ImagePolicy
name: '*'
- kind: ImageUpdateAutomation
name: '*'
providerRef:
name: notification-provider-slack
notification-provider-slack.yaml
apiVersion: notification.toolkit.fluxcd.io/v1beta3
kind: Provider
metadata:
name: notification-provider-slack
namespace: flux-system
spec:
address: https://slack.com/api/chat.postMessage
channel: k8s-channel
secretRef:
name: slack-secret
type: slack
username: FluxCD
After that, open the kustomization.yaml file inside the same folder and add new entries referencing the two files you created above.
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- gotk-components.yaml
- gotk-sync.yaml
- helmrepositories/cert-manager.yaml
- helmrepositories/sealed-secrets.yaml
- imagerepositories/lms-static-canary.yaml
- imagepolicies/lms-static-canary.yaml
- image-update-automation.yaml
- acr-secret-enc.yaml
- secret-enc.yaml
- notification-provider-slack.yaml
- notification-alert-slack.yaml
Then, commit and push the changes to the GitHub repository. After that, reconcile the cluster using the flux reconcile command.
flux reconcile source git -n flux-system flux-system
Now, go to your Slack workspace and you will see a message sent from FluxCD. The message will appear with a green indicator, which means the configuration process has been completed successfully.

Check the Slack working or not
Finally, you can verify whether the Slack integration is working correctly.
Make any update or modification to a file in your cluster. For example open the deployment-stable.yaml file and change the number of replicas to 5.
After making the change, commit and push it to your GitHub repository, then run the flux reconcile command.
Next, go to your Slack workspace and refresh it. You will see a new message generated based on the update you made earlier. This confirms that the Slack integration is working properly and that FluxCD is sending notifications as expected.

With the Slack workspace, it becomes very easy to identify deployment logs. If a user updates or modifies any part of the cluster and the change is successful, the final Slack notification will appear in green, indicating everything worked correctly.
If there is any issue or error during the process, the final output will appear in red, clearly explaining the reason for the failure and helping you quickly identify what went wrong.
Additionally, if you find this entire file and folder structure difficult to follow, you can refer to the GitHub repository below. It contains the complete project with all configurations used in this setup.
🔗 GitHub Repository: https://github.com/tharinduk001/helm-istio-certmanager-v2
Conclusion
Integrating Slack with FluxCD enables real-time notifications for Kubernetes deployments, allowing developers to monitor changes without manually checking complex log files. By configuring a Slack workspace, creating a Slack app, and securely storing the OAuth token using Kubernetes secrets and Sealed Secrets, FluxCD can send deployment alerts directly to Slack channels. This integration improves visibility, speeds up troubleshooting, and creates a more efficient GitOps workflow for managing Kubernetes environments.
Final Thoughts on the Kubernetes Workshop Series
This blog marks the final article in my Kubernetes workshop learning journey. Throughout this series, we explored several important concepts in modern cloud-native environments, including containerization, Kubernetes architecture, Helm, Istio service mesh, cert-manager, secret management with Sealed Secrets, canary deployments, automated image updates, and GitOps-based continuous delivery using FluxCD.
Each step helped build a deeper understanding of how real-world Kubernetes environments are designed and managed using automation and best practices. By combining these tools and techniques, we created a more reliable, secure, and scalable deployment workflow for applications running in Kubernetes.
This workshop has been an incredibly valuable learning experience, strengthening my knowledge in Cloud, DevOps, and Kubernetes ecosystem technologies. I hope this blog series also helps others who are interested in learning Kubernetes and GitOps workflows.
Thank you for following along with this journey, and I look forward to continuing to explore and share more knowledge in the cloud-native and DevOps space in the future. 🚀
🤝 Let’s Connect
This blog series documented my Kubernetes and Cloud Native learning journey throughout this workshop. Sharing these weekly learnings helped me reinforce my understanding while contributing knowledge to the community.
If you are also exploring Kubernetes, DevOps, or Cloud technologies, feel free to connect with me and share ideas, experiences, and insights.
🔗 LinkedIn: linkedin.com/in/sasankad101 💬 I’m always open to discussions, feedback, and collaboration opportunities.
Let’s continue learning and growing together in the Cloud Native ecosystem 🚀
메타데이터
- post_id
- ff0e63d8422b
- slug
- slack-integration-with-fluxcd-for-real-time-kubernetes-deployment-notifications-ff0e63d8422b
- url
- https://blog.devops.dev/slack-integration-with-fluxcd-for-real-time-kubernetes-deployment-notifications-ff0e63d8422b
- canonical_url
- https://blog.devops.dev/slack-integration-with-fluxcd-for-real-time-kubernetes-deployment-notifications-ff0e63d8422b
- author_url
- https://medium.com/@sasankad101
- status
- ok
- fetched_at
- 2026-07-27 17:46:35