• 告警通知
  • webhook(企业微信机器人)无法收到消息

NullFox 看下了你发的文档,我这边的企业微信机器人,实际上只需要一个URL字段就可以,因为key直接填在了url里面:

比如https://qyapi.weixin.qq.com/cgi-bin/webhook/send?key=xxx

这个使用起来就是一个curl的命令就行了,例如:

curl 'https://qyapi.weixin.qq.com/cgi-bin/webhook/send?key=xxxx' \
   -H 'Content-Type: application/json' \
   -d '
   {
        "msgtype": "text",
        "text": {
            "content": "hello world"
        }
   }'

文档中,我应该使用哪种类型的通知?Webhook Receiver 还是WeChat Chatbot

感谢回复!

NullFox

wanjunlei

已成功发送告警,感谢。

不过还是希望能在web界面上增加个一键配置的地方(更友好,更小白)

    24 天 后

    NullFox

    现在配置企业微信,创建应用的方式一直出错。我们两年前用的v3.1.1版本,现在项目太多,也不知道升级会不会影响到

      NullFox 大佬,像我们现在使用kubesphere/notification-manager:v1.0.0版本,有办法单独升级这个组件,支持企业微信通知吗。

      hanyce 您好,您这边使用什么kubesphere哪个版本,是在后台自己配置企业微信通知吗

      helloJackYang 企业微信之前他们更新过,然后需要设置什么ip白名单了,具体的你可以去看一下企微的文档。如果要使用企业微信机器人那得notification-manager 2.2版本以后才可以

        NullFox 可以单独升级notification-manager版本,并使用微信机器人通知的方式吗。目前是notification-manager:v1.0.0

        可以,不过你的数据重要的话,建议你先创建个测试集群先尝试一下。

          NullFox 生产环境是在2022年使用kubesphere-installer.yaml创建的,使用阿里云ACK托管版本。我现在本地虚拟机加了一个版本一样,也是v3.1.1,但使用是kk方式部署的

          NullFox [root@node1 kubernetes]# helm upgrade notification-manager -n kubesphere-monitoring-system notification-manager.tgz

          Error: UPGRADE FAILED: rendered manifests contain a resource that already exists. Unable to continue with update: Secret “notification-manager-webhook-server-cert” in namespace “kubesphere-monitoring-system” exists and cannot be imported into the current release: invalid ownership metadata; label validation error: missing key “app.kubernetes.io/managed-by”: must be set to “Helm”; annotation validation error: missing key “meta.helm.sh/release-name”: must be set to “notification-manager”; annotation validation error: missing key “meta.helm.sh/release-namespace”: must be set to “kubesphere-monitoring-system”

          [root@node1 kubernetes]#