apiVersion: dedicated.regionalserver.tidbcloud.com/v1alpha1
kind: APPRoute
metadata:
  finalizers:
    - dedicated.regionalserver.tidbcloud.com/finalizer
  annotations:
  labels:
    cloud.pingcap.com/manage: full
    cloud.pingcap.com/tenantId-foo: "true"
    cloud.pingcap.com/projectId-foo: "true"
    cloud.pingcap.com/clusterId-foo: "true"
    cloud.pingcap.com/clusterId: "foo"
    cloud.pingcap.com/appboxName: "foo"
    cloud.pingcap.com/vpcName: "foo"
    cloud.pingcap.com/region: us-west-2
  name: foo
  namespace: foo
spec:
  appboxRef:
    namespace: foo
    name: foo
  forCluster: |-
    {
      "id": "foo",
      "tenantId": "foo",
      "projectId": "foo",
      "componentNodeSpecs": [
        {
          "componentType": "TIKV",
          "instanceType": "foo",
          "count": 10,
          "storage": {
            "type": "foo",
            "sizeGi": 10,
            "iops": 10,
            "throughputMbs": 10
          }
        },
        {
          "componentType": "TIDB",
          "instanceType": "foo",
          "count": 10
        }
      ],
      "componentConfigurations": [
        {
          "configurationFileContents": "foo",
          "componentType": "TIKV"
        },
        {
          "configurationFileContents": "foo",
          "componentType": "TIDB"
        }
      ],
      "clusterVersion": {
        "clusterVersion": "v1.0.0",
        "componentVersions": [
          {
            "componentType": "TIKV",
            "imageRepo": "foo",
            "imageTag": "foo"
          },
          {
            "componentType": "TIDB",
            "imageRepo": "foo",
            "imageTag": "foo"
          }
        ]
      },
      "vpcSettings": {
        "existingAwsVpcId": "vpc-foo"
      },
      "securityConfigurations": {
        "cmekAwsMasterKeyArn": "foo",
        "tidbAuthTokenJwks": "foo",
        "auditLogConfiguration": {
          "bucketUrl": "foo",
          "bucketRegion": "us-west-2",
          "s3": {
            "roleArn": "foo"
          }
        },
        "sqlClientCa": "foo"
      },
      "clusterIdentifierHash": "foo",
      "port": 80,
      "initSqlStatements": "foo"
    }
status:
  phase: Active
