Charmed PostgreSQL K8s

Channel Revision Published Runs on
latest/stable 20 20 Sep 2022
Ubuntu 20.04
14/stable 193 13 Mar 2024
Ubuntu 22.04
14/candidate 193 31 Jan 2024
Ubuntu 22.04
14/beta 211 13 Mar 2024
Ubuntu 22.04
14/edge 240 Yesterday
Ubuntu 22.04
juju deploy postgresql-k8s --channel 14/stable
Show information

Platform:

charms.postgresql_k8s.v0.postgresql_tls

In this class we manage certificates relation.

This class handles certificate request and renewal through the interaction with the TLS Certificates Operator.

This library needs that https://charmhub.io/tls-certificates-interface/libraries/tls_certificates library is imported to work.

It also needs the following methods in the charm class: — get_hostname_by_unit: to retrieve the DNS hostname of the unit. — get_secret: to retrieve TLS files from secrets. — push_tls_files_to_workload: to push TLS files to the workload container and enable TLS. — set_secret: to store TLS files as secrets. — update_config: to disable TLS when relation with the TLS Certificates Operator is broken.


class PostgreSQLTLS

Description

In this class we manage certificates relation. None

Methods

PostgreSQLTLS. __init__( self , charm , peer_relation: str , additional_dns_names )

Description

Manager of PostgreSQL relation with TLS Certificates Operator. None

PostgreSQLTLS. get_tls_files( self )

Prepare TLS files in special PostgreSQL way.

Description

PostgreSQL needs three files: — CA file should have a full chain. — Key file should have private key. — Certificate file should have certificate without certificate chain.