apiVersion: v1
data:
  application-prod.yaml: |+
    spring:
      datasource:
        url: jdbc:mysql://hawk-mysql-headless:3306/{{ .Values.mysql.auth.database }}?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull&serverTimezone=GMT%2B8
        username: root
        password: {{ .Values.mysql.auth.rootPassword }}
      redis:
        host: hawk-redis-headless
        password: {{ .Values.redis.password }}
      kafka:
        bootstrap-servers: {{ .Values.hawk.kafka.url }}
    eureka:
      client:
        serviceUrl:
          defaultZone: http://default-eureka-server:8080/eureka
    hawk:
      container:
        default-instance-namespace: {{.Values.hawk.appns}}
        domain-host: {{ .Values.hawk.host }}
        build-namespace: {{ default "build" .Values.hawk.build.namespace }}
        app-image-prefix: {{ .Values.hawk.appImagePrefix }}
        gateway-url: hawk-gateway.hawk:8080
        pvc-log: true
      runtime:
        buildVolume: lib-repo
        config:
          nginx:
            runtime:
              appImage: registry.cn-qingdao.aliyuncs.com/kangta123/hawk_nginx:{{ .Values.hawk.deps.version }}
              dataImage: registry.cn-qingdao.aliyuncs.com/kangta123/hawk_init_npm:{{ .Values.hawk.deps.version }}
              podInteractionVolume: /tmp/app:/usr/local/openresty/nginx/html
            build:
              npm:
                image: registry.cn-qingdao.aliyuncs.com/kangta123/hawk_npm_build:{{ .Values.hawk.deps.version }}
                sub: npm
          tomcat:
            runtime:
              appImage: registry.cn-qingdao.aliyuncs.com/kangta123/hawk_tomcat8:{{ .Values.hawk.deps.version }}
              dataImage: registry.cn-qingdao.aliyuncs.com/kangta123/hawk_init_tomcat:{{ .Values.hawk.deps.version }}
              podInteractionVolume: /tmp/app:/usr/local/apache-tomcat-8.5.46/webapps/ROOT
            build:
              maven:
                image: registry.cn-qingdao.aliyuncs.com/kangta123/hawk_maven_build:{{ .Values.hawk.deps.version }}
                volume:
                  sub: maven
                  mountPath: /root/.m2/
          springboot:
            runtime:
              appImage: registry.cn-qingdao.aliyuncs.com/kangta123/hawk_springboot8:{{ .Values.hawk.deps.version }}
              dataImage: registry.cn-qingdao.aliyuncs.com/kangta123/hawk_init_springboot:{{ .Values.hawk.deps.version }}
              podInteractionVolume: /tmp/app:/app/jar
            build:
              maven:
                image: registry.cn-qingdao.aliyuncs.com/kangta123/hawk_maven_build:{{ .Values.hawk.deps.version }}
                volume:
                  sub: maven
                  mountPath: /root/.m2/
              gradle:
                image: registry.cn-qingdao.aliyuncs.com/kangta123/hawk_gradle_build:{{ .Values.hawk.deps.version }}
                volume:
                  sub: gradle
                  mountPath: /gradle

kind: ConfigMap
metadata:
  name: hawk-container-config
