Skip to content

Commit 52bcaa5

Browse files
souravbiswassantoArnobKumarSaha
authored andcommitted
Resolve Reviews
Signed-off-by: souravbiswassanto <[email protected]>
1 parent e1bba44 commit 52bcaa5

File tree

1 file changed

+56
-78
lines changed
  • docs/guides/postgres/distributed/overview

1 file changed

+56
-78
lines changed

docs/guides/postgres/distributed/overview/index.md

Lines changed: 56 additions & 78 deletions
Original file line numberDiff line numberDiff line change
@@ -502,6 +502,59 @@ Verify the worker installation:
502502
spire-install-crds-cnbjh 0/1 Completed 0 4m50s
503503
```
504504

505+
**Onboard Database Namespace**
506+
507+
508+
Create a `SliceConfig` to onboard the `demo` (application) and `kubedb` (operator) namespaces for network connectivity. Create a `sliceconfig.yaml` file:
509+
510+
```yaml
511+
apiVersion: controller.kubeslice.io/v1alpha1
512+
kind: SliceConfig
513+
metadata:
514+
name: demo-slice
515+
namespace: kubeslice-demo-distributed-postgres
516+
spec:
517+
sliceSubnet: 10.1.0.0/16
518+
maxClusters: 16
519+
sliceType: Application
520+
sliceGatewayProvider:
521+
sliceGatewayType: Wireguard
522+
sliceCaType: Local
523+
sliceIpamType: Local
524+
rotationInterval: 60
525+
vpnConfig:
526+
cipher: AES-128-CBC
527+
clusters:
528+
- demo-controller
529+
- demo-worker
530+
qosProfileDetails:
531+
queueType: HTB
532+
priority: 1
533+
tcType: BANDWIDTH_CONTROL
534+
bandwidthCeilingKbps: 5120
535+
bandwidthGuaranteedKbps: 2560
536+
dscpClass: AF11
537+
namespaceIsolationProfile:
538+
applicationNamespaces:
539+
- namespace: demo
540+
clusters:
541+
- '*'
542+
- namespace: kubedb
543+
clusters:
544+
- '*'
545+
isolationEnabled: false
546+
allowedNamespaces:
547+
- namespace: kube-system
548+
clusters:
549+
- '*'
550+
```
551+
552+
Apply the `SliceConfig`:
553+
554+
```bash
555+
kubectl apply -f sliceconfig.yaml
556+
```
557+
505558
### Step 4: Install the KubeDB Operator
506559

507560
Install the KubeDB Operator on the `demo-controller` cluster to manage the Postgres instance.
@@ -511,7 +564,7 @@ Download a FREE license from [AppsCode License Server](https://appscode.com/issu
511564

512565
```bash
513566
helm upgrade -i kubedb oci://ghcr.io/appscode-charts/kubedb \
514-
--version v2025.7.31 \
567+
--version v2025.8.31 \
515568
--namespace kubedb --create-namespace \
516569
--set-file global.license=$HOME/Downloads/kubedb-license-cd548cce-5141-4ed3-9276-6d9578707f12.txt \
517570
--set petset.features.ocm.enabled=true \
@@ -565,82 +618,7 @@ Apply the policy on `demo-controller`:
565618
kubectl apply -f podplacementpolicy.yaml --context demo-controller --kubeconfig $HOME/.kube/config
566619
```
567620

568-
### Step 6: Onboard Application Namespace
569-
570-
571-
Create a `SliceConfig` to onboard the `demo` (application) and `kubedb` (operator) namespaces for network connectivity. Create a `sliceconfig.yaml` file:
572-
573-
```yaml
574-
apiVersion: controller.kubeslice.io/v1alpha1
575-
kind: SliceConfig
576-
metadata:
577-
name: demo-slice
578-
namespace: kubeslice-demo-distributed-postgres
579-
spec:
580-
sliceSubnet: 10.1.0.0/16
581-
maxClusters: 16
582-
sliceType: Application
583-
sliceGatewayProvider:
584-
sliceGatewayType: Wireguard
585-
sliceCaType: Local
586-
sliceIpamType: Local
587-
rotationInterval: 60
588-
vpnConfig:
589-
cipher: AES-128-CBC
590-
clusters:
591-
- demo-controller
592-
- demo-worker
593-
qosProfileDetails:
594-
queueType: HTB
595-
priority: 1
596-
tcType: BANDWIDTH_CONTROL
597-
bandwidthCeilingKbps: 5120
598-
bandwidthGuaranteedKbps: 2560
599-
dscpClass: AF11
600-
namespaceIsolationProfile:
601-
applicationNamespaces:
602-
- namespace: demo
603-
clusters:
604-
- '*'
605-
- namespace: kubedb
606-
clusters:
607-
- '*'
608-
isolationEnabled: false
609-
allowedNamespaces:
610-
- namespace: kube-system
611-
clusters:
612-
- '*'
613-
```
614-
615-
Apply the `SliceConfig`:
616-
617-
```bash
618-
kubectl apply -f sliceconfig.yaml
619-
```
620-
621-
Restart all pods in the `kubedb` namespace to inject KubeSlice sidecar containers:
622-
623-
```bash
624-
kubectl delete -n kubedb pod --all
625-
```
626-
627-
Verify the pods restart and are running:
628-
629-
```bash
630-
kubectl get pods -n kubedb
631-
```
632-
**Output**:
633-
```
634-
NAME READY STATUS RESTARTS AGE
635-
kubedb-kubedb-autoscaler-0 1/2 Running 0 44s
636-
kubedb-kubedb-ops-manager-0 1/2 Running 0 43s
637-
kubedb-kubedb-provisioner-0 1/2 Running 0 43s
638-
kubedb-kubedb-webhook-server-df667cd85-tjdp9 2/2 Running 0 44s
639-
kubedb-petset-cf9f5b6f4-d9558 2/2 Running 0 44s
640-
kubedb-sidekick-5dbf7bcf64-4b8cw 2/2 Running 0 44s
641-
```
642-
643-
### Step 7: Create a Distributed Postgres Instance
621+
### Step 6: Create a Distributed Postgres Instance
644622

645623
Define a Postgres custom resource with `spec.distributed: true` and reference the `PlacementPolicy`. Example:
646624

@@ -674,7 +652,7 @@ Apply the resource on `demo-controller`:
674652
kubectl apply -f postgres.yaml --context demo-controller --kubeconfig $HOME/.kube/config
675653
```
676654

677-
### Step 8: Verify the Deployment
655+
### Step 7: Verify the Deployment
678656

679657
1. **Check Postgres Resource and Pods on `demo-controller`**:
680658

0 commit comments

Comments
 (0)