apiVersion: cloud.pingcap.com/v1
kind: Provider
metadata:
  name: gke
spec:
  type: gke
  storageClasses:
    - name: tikv-pd-ssd
      type: pd-ssd
    - name: tiflash-pd-ssd
      type: pd-ssd
    - name: pd-pd-ssd
      type: pd-ssd
    - name: index-acceleration
      type: pd-ssd
  regions:
    - name: us-west1
      zones:
        - us-west1-a
        - us-west1-b
        - us-west1-c
    - name: us-west2
      zones:
        - us-west2-a
        - us-west2-b
        - us-west2-c
  instanceTypes:
    - name: n1-standard-1
      regions: ["us-west1", "us-west2"]
      arch: amd64
      cpu: 1
      memory: 3Gi
      minStorage: 0Gi
      maxStorage: 100Gi
    - name: n1-standard-2
      regions: ["us-west1", "us-west2"]
      arch: amd64
      cpu: 2
      # machine memory actual 7.5Gi
      # align with https://github.com/tidbcloud/cluster-tier-config/pull/25/files
      memory: 7Gi
    - name: n1-standard-4
      regions: ["us-west1", "us-west2"]
      arch: amd64
      cpu: 4
      memory: 15Gi
    - cpu: "8"
      memory: 30Gi
      name: n1-standard-8
      regions: ["us-west1", "us-west2"]
      arch: amd64
    - cpu: "32"
      memory: 120Gi
      name: n1-standard-32
      regions: ["us-west1", "asia-northeast1", "asia-southeast1", "us-central1"]
      arch: amd64
    - cpu: "8"
      memory: 52Gi
      name: n1-highmem-8
      regions: ["us-west1", "us-west2"]
      arch: amd64
    - name: n2-custom-4-8192
      regions: ["us-west1", "us-west2"]
      arch: amd64
      cpu: 4
      memory: 8Gi
    - name: n2-custom-8-16384
      regions: ["us-west1", "us-west2"]
      arch: amd64
      cpu: 8
      memory: 16Gi
    - name: n2-standard-4
      regions: ["us-west1", "us-west2"]
      arch: amd64
      cpu: 4
      memory: 16Gi
    - name: n2-standard-8
      cpu: 8
      arch: amd64
      memory: 32Gi
      regions: ["us-west1", "us-west2"]
      unavailableMemory: 2Gi
    - name: n2-highmem-8
      cpu: 8
      arch: amd64
      memory: 64Gi
      unavailableMemory: 2Gi
      localStorageSize: 1500Gi
      minStorage: 1500Gi
      maxStorage: 1500Gi
      regions: ["us-west1", "us-west2"]
    - name: n2-standard-2
      cpu: 2
      arch: amd64
      memory: 8Gi
      minStorage: 0Gi
      maxStorage: 500Gi
      regions: ["us-west1", "us-west2"]
    - name: g1-small
      cpu: 1
      arch: amd64
      memory: 1.7Gi
      minStorage: 0Gi
      maxStorage: 50Gi
      regions: ["us-west1", "us-west2"]
    - name: e2-medium
      cpu: 1
      arch: amd64
      memory: 4Gi
      minStorage: 0Gi
      maxStorage: 500Gi
      regions: ["us-west1", "us-west2"]
  forProvider:
    apiVersion: cloud.pingcap.com/v1
    kind: GardenerProviderSpec
    # TODO: the relate.. reporter in dbaas
    enableGracefulShutdownWebhook: true
    reporter:
      image: "dbaas/dev/billing-reporter:5361cfdaede17bc8f46c0cca7d862aa7d88cd8ea"
      sqsEndpoint: "https://sqs.us-west-2.amazonaws.com/385595570414/nightly-billing.fifo"
      region: "us-west-2"
    sliReporter:
      image: "dbaas/dev/sli-reporter:42a6322f4062df718ef88a3ea46b29afafa6aa1f"
      sqsEndpoint: "https://sqs.us-west-2.amazonaws.com/385595570414/ingress-mim.fifo"
      region: "us-west-2"
    proxy:
      # TODO: the proxy.. reporter in dbaas
      image: "dbaas/dev/cluster-proxy:v1.2.16"
      auth0Audience: "dev-proxy-service"
      auth0Domain: "tidb-dev.us.auth0.com"
    topsql:
      image: "dbaas/dev/topsql-agent:511df4e3c487ed0cc324d306a83fea4633dc4ddb"
    gcp:
      publicHostedZoneDomain: dev.gcp.tidbcloud.com
      publicHostedZoneId: "557076687191963248"
      crossplaneProvider: provider-gcp
      projectID: "pingcap-gardener"
      certManagerRole: "projects/pingcap-gardener/roles/devCertManager"
    # currently gke cluster also relies some aws resources
    aws:
      accountID: "385595570414"
      crossplaneProvider: provider-aws
      pcaArn: "arn:aws:acm-pca:us-west-2:385595570414:certificate-authority/4668d5cc-1042-4371-9ff4-72ab9493c545"
      pcaRegion: "us-west-2"
