## Access the base cluster

infra-api is deployed at dev-base-us-west-2/infra

please check [operation-101](https://github.com/tidbcloud/infra/blob/master/docs/operation-101.md) about how to access the base cluster

to check all the pods

```shell
$ kubectx
Switched to context "arn:aws:eks:us-west-2:385595570414:cluster/dev-base-us-west-2".
$ get po -n infra
NAME                             READY   STATUS    RESTARTS   AGE
api-server-f8498fdf6-mtl8p       2/2     Running   1          7d15h
api-server-f8498fdf6-th5dv       2/2     Running   1          7d15h
api-server-f8498fdf6-vvvfq       2/2     Running   1          7d15h
aws-provider-b599cfb6d-qlwlq     1/1     Running   0          4h24m
etcd-0                           1/1     Running   0          13d
etcd-1                           1/1     Running   0          16d
etcd-2                           1/1     Running   0          16d
gcp-provider-5f968bbcb7-2g5s8    1/1     Running   0          3d18h
infra-provider-d9c9cdb6c-75hln   1/1     Running   0          71m
infra-provider-d9c9cdb6c-fjw56   1/1     Running   0          71m
```

## Access infra-api api-server

- Please check [operation-101](https://github.com/tidbcloud/infra/blob/master/docs/operation-101.md) to ensure `gcloud` has been installed and configured
- For dev environment, please ensure your PingCAP email is configured in `./projects/infra-api/Pulumi.dev.yaml`

### Get api-server kubeconfig

under dev-base-us-west-2 context

```shell
$ k get secret api-server-oidc-kubeconfig -n infra --template={{'.data.config'}} | base64 -d > dev-infra.kubeconfig
```

test with the kubeconfig

```shell
$ KUBECONFIG=./dev-infra.kubeconfig k get network.cloud.pingcap.com
NAME             PHASE    SHOOT      BUCKET
network-sample   Normal   cf124554   dbaas-infra-dev-us-west-2-1234560
```

## DBaaS

A relate environment is deploy using `infra-dev` as gardener project name, please see [development-env](https://github.com/tidbcloud/dbaas/blob/master/docs/development/development-env.md) for detail.

To Access DBaaS [insert you user using your email](https://github.com/tidbcloud/dbaas/blob/master/docs/development/development-env.md#6-add-your-account-to-pingcap-organization-and-init-tier) and [configure frontend to use `infra-dev` backend](https://github.com/tidbcloud/dbaas/blob/master/docs/development/development-env.md#7-configure-frontend-to-use-your-backend)(https://us-west-2.infra-dev.shared.aws.tidbcloud.com).
