postgresql-k8s

Charmed PostgreSQL K8s

Channel Revision Published Runs on
latest/stable 20 20 Sep 2022
Ubuntu 20.04
14/stable 495 18 Feb 2025
Ubuntu 22.04
14/stable 494 18 Feb 2025
Ubuntu 22.04
14/candidate 495 11 Feb 2025
Ubuntu 22.04
14/candidate 494 11 Feb 2025
Ubuntu 22.04
14/beta 495 06 Feb 2025
Ubuntu 22.04
14/beta 494 06 Feb 2025
Ubuntu 22.04
14/edge 508 Today
Ubuntu 22.04
14/edge 507 Today
Ubuntu 22.04
16/edge 496 06 Feb 2025
Ubuntu 24.04
juju deploy postgresql-k8s --channel 14/edge
Show information

Platform:

How to deploy

This page aims to provide an introduction to the PostgreSQL deployment process and lists all the related guides. It contains the following sections:


General deployment instructions

The basic requirements for deploying a charm are the Juju client and a Kubernetes cloud.

First, bootstrap the cloud controller and create a model:

juju bootstrap <cloud name> <controller name>
juju add-model <model name>

Then, either continue with the juju client or use the terraform juju client to deploy the PostgreSQL charm.

To deploy with the juju client:

juju deploy postgresql-k8s --trust

See also: juju deploy command

To deploy with terraform juju, follow the guide How to deploy using Terraform.

See also: Terraform Provider for Juju documentation

If you are not sure where to start or would like a more guided walkthrough for setting up your environment, see the Charmed PostgreSQL K8s tutorial.

Clouds

The guides below go through the steps to install different cloud services and bootstrap them to Juju:

How to deploy on multiple availability zones (AZ) demonstrates how to deploy a cluster on a cloud using different AZs for high availability.

Special deployments

These guides cover some specific deployment scenarios and architectures.

External network access

See How to connect from outside the local network for guidance on connecting with a client application outside PostgreSQL’s Kubernetes cluster.

Airgapped

How to deploy in an offline or air-gapped environment goes over the special configuration steps for installing PostgreSQL in an airgapped environment via CharmHub and the Snap Store Proxy.

Cluster-cluster replication

Cluster-cluster, cross-regional, or multi-server asynchronous replication focuses on disaster recovery by distributing data across different servers.

The Cross-regional async replication guide goes through the steps to set up clusters for cluster-cluster replication, integrate with a client, and remove or recover a failed cluster.