kind: ConfigMap
apiVersion: v1
metadata:
  name: message
  namespace: lowcode
  annotations:
    kubesphere.io/creator: zhenlinding
data:
  config.yml: |
    # port 端口
    # e.g :80
    port: :80

    # model 模式 debug|release
    # debug模式，可以输出更加详细的日志，但是运行速度会减慢
    model: debug

    # processorNum 分发并行数
    processorNum: 5

    # 站内信发送地址
    messageAPI: http://%s:80/api/v1/message/send
    #token验证
    auth:
      checktoken: http://jwt/api/v1/jwt/check

    # syncChannel 内部分布式同步
    syncChannel: dispatcher:task:listen:rest

    #  -------------------- hand out --------------------
    handout:
      deadline: 30
      dialTimeout: 30
      maxIdleConns: 10

    #  -------------------- log --------------------
    # comply with zap log specification
    log:
      level: -1
      development: false
      sampling:
        initial: 100
        thereafter: 100
      outputPath:
        - stderr
      errorOutputPath:
        - stderr

    #  -------------------- internalNet --------------------
    internalNet:
      timeout: 20
      maxIdleConns: 10

    # -------------------- kafka --------------------
    kafka:
      {{- with .Values.config.kafka.broker }}
      broker:
        {{- toYaml . | nindent 8 }}
      {{- end }}
    # -------------------- mysql --------------------
    mysql:
      db: {{ .Values.config.mysql.db }}
      host: {{ .Values.config.mysql.host }}
      user: {{ .Values.config.mysql.user }}
      password: {{ .Values.config.mysql.password }}
      log: {{ .Values.config.mysql.log }}

    redis:
      {{- with .Values.config.redis.addrs }}
      addrs:
        {{- toYaml . | nindent 8 }}
      {{- end }}
      username: {{ .Values.config.redis.username }}
      password: {{ .Values.config.redis.password }}


    email:
