更新时间:2024-03-07 GMT+08:00
分享

配置demo

# resources.yaml
- name: sdkCluster
  type: WiseCloud::MicroService::NuwaContainer
  properties:
    microserviceName: WiseCloudNuwaSDK    # STS证书中服务的名称
    replicas:
      $ref: 'config/values.yaml#/values/replicas'
    terminationGracePeriodSeconds: 30
    network:
      slbEnable:
        $ref: 'config/values.yaml#/values/slbEnable'
      isolatedDomain: XXX
    volumes:
      - name: log_volume
        size: 10Gi
        type: local
      - name: data_volume
        size: 2Gi
        type: local
    containers:                          # 微服务基于容器化的部署
      - image:
          $ref: 'config/values.yaml#/values/image'
        flavor: 2C4G
        stsEnable: true
        ports:
          - 8080
        livenessProbe:
          httpGet:
            path: /health.html
            port: 8080
            scheme: HTTP
          initialDelaySeconds: 20
          timeoutSeconds: 3
          periodSeconds: 10
          successThreshold: 1
          failureThreshold: 3
        readinessProbe:
          httpGet:
            path: /health.html
            port: 8080
            scheme: HTTP
          initialDelaySeconds: 20
          timeoutSeconds: 3
          periodSeconds: 10
          successThreshold: 1
          failureThreshold: 10
        preStopConfig:
          execCommand: ["/bin/bash", "-c", "sleep 20"]
        envs:
          $ref: 'config/envs.yaml#'
        hostAliases:
          - hostName: "a.b.com"
            ip: "1:1:1:1:1:1:1:1"
          - hostName: "c.d.com"
            ip: "2.2.2.2"
	certConfigs:                      # 可选
          - name: console
            tag: default
    configs:
      $ref: 'config/business_config.yaml#'
    daemonSet: 
      - name: AIOps
        enable: true
        logPath: '/opt/huawei/logs'
        limitSize: 100G
        groups: ["logConfigGroupName"]
      - name: BI
        enable: false
        logPath: '/opt/huawei/logs/bi'
        groups: ["ODS_V001_DM_service1", "ODS_V001_DM_service2"]
    sidecars:
      - name: AIOpsLog
        version: 1.11.3.100
        flavor: 0.4C500M
        param:
          $ref: 'config/sidecar_aiops_param.json'
       - name: RASP
        version: 2.2.0.102.SP5
        flavor: 0.3C500M
    bindSlb:
      - port: 8080
        grayStatus: 1
        weight: 20
        maxFails: 3
        timeout: 20
        instanceName: chaos_slb_listener_lhq
        listenerGroupName: chaos_slb_listener_lhq
        targetGroup:
          name: chaosmonekey_portal_static

# business_config.yaml 
public:
  prefix: /com.huawei.wiseeye
  name: public5
private:
  schema:
    type: object
    properties:
      AIOPSCONFIG_AIOPSSERVER:
        format: notype
      AIOPSCONFIG_AIOPSTOKENURI:
        format: sensitive
  records:
    AIOPSCONFIG_AIOPSSERVER: 'https://XX.XX.XX.XX:XXXX/'
    AIOPSCONFIG_AIOPSTOKENURI: openapi/XXX/XXX/
分享:

    相关文档

    相关产品