In this section you will find examples and information on how to run Postgres in Kubernetes using CloudNativePG.
It is important that you have enough skills in the Kubernetes administration area. In our experience, having equivalent CKA and/or CKAD skills helps.
In order to proceed with the examples, you need to have successfully installed:
- kubectl: the primary command-line tool to manage Kubernetes clusters
- kind: a Kubernetes distribution that works inside Docker, creating a new container for each node.
Our examples will use a local Kubernetes cluster in Kind made up of 3 worker nodes.
curl \
https://raw.githubusercontent.com/gbartolini/postgres-kubernetes-playground/main/kind/3node-kind.yaml \
--output /tmp/3node-kind.yaml
kind create cluster --config /tmp/3node-kind.yaml
Once you are done, you can delete the cluster with:
kind delete cluster
If you want to setup a playground for CloudNativePG in EKS, look at the
awk-eks
folder.