Member-only story
Postgres Deployment with CloudNativePG
In the previous two articles, we deploy PostgresSQL databases using manifest files and helm package manager. Another way to deploy them is using Kubernetes operators. There are many Postgres operators such as Zalando Postgres Operator, Crunchy Data Postgres Operator (PGO), Percona Operator for Postgres, CloudNativePG, PostgresSQL Operator by KubeDB, Stackgres Operator. These operators aim to provide various features: backup/restore, HA (highly available) features, failure recovery, connection pooling, monitoring and other enterprise-grade features.
In this article, we provide steps to deploy CloudNativePG operator and set up a Postgres cluster using it.
CloudNativePG Helm Installation
The following sequence of helm commands will deploy CloudNativePG operator.
helm repo add cnpg https://cloudnative-pg.github.io/charts
helm repo update cnpg
helm search repo cnpg
helm fetch cnpg/cloudnative-pg --version 0.23.0 --untar
helm upgrade --install -n cnpg cnpg ./cloudnative-pg \
--values ./override.yaml --create-namespace
The override values is shown below.
---
rbac:
aggregateClusterRoles: true
Various installed components are shown with associated the commands.
