How to deploy on MicroK8s
This guide assumes you have a running Juju and MicroK8s environment.
For a detailed walkthrough of setting up an environment and deploying the charm on MicroK8s, refer to the following Tutorial pages:
- 1. Set up the environment - set up Multipass and Juju
- 2. Deploy PostgreSQL - deploy PostgresQL K8s in a Multipass instance
MicroK8s can be installed on a multitude of platforms and environments for different use cases. See all options and details in the official documentation.
Not all platforms supported by MicroK8s will work with this charm - keep in mind the system requirements of Charmed PostgreSQL.
Prerequisites
- Canonical MicroK8s 1.27+
- Fulfill the general system requirements
Bootstrap a juju controller and create a model if you haven’t already:
juju bootstrap localhost <controller name>
juju add-model <model name>
Deploy PostgreSQL K8s:
juju deploy postgresql-k8s --trust
The
--trustflag is necessary to create some K8s resources
See the
juju deploydocumentation for all available options at deploy time.See the Configurations tab for specific PostgreSQL K8s parameters.
Example juju status --wait 1s output:
Model Controller Cloud/Region Version SLA Timestamp
example charm-dev microk8s/localhost 2.9.42 unsupported 12:00:43+01:00
App Version Status Scale Charm Channel Rev Address Exposed Message
postgresql-k8s active 1 postgresql-k8s 14/stable 56 10.152.183.167 no
Unit Workload Agent Address Ports Message
postgresql-k8s/0* active idle 10.1.188.206