Skip to content

Share single certificate between units in HA deployment #366

@alexdlukens

Description

@alexdlukens

Enhancement Proposal

Currently the haproxy-operator charm uses the TLSCertificateRequiresV4 in UNIT mode:

self.certificates = TLSCertificatesRequiresV4(
charm=self,
relationship_name=TLS_CERT_RELATION,
certificate_requests=self._get_certificate_requests(),
refresh_events=[
self.on.config_changed,
self.haproxy_route_provider.on.data_available,
self.haproxy_route_provider.on.data_removed,
],
mode=Mode.UNIT,
)

This means that in HA deployments, a separate certificate is requested for each unit. Let's Encrypt only permits a maximum of 5 certificates to be requested for a given domain across 168h. This means if there is there is an error with the initial certificate issuing, users must potentially wait several days before requesting a new cert.

We have regularly seen this issue in production use with PS7 ingress environments.

This feature request is to request using mode.APP for TLSCertificateRequiresV4 and sharing the single certificate to other units in the HA deployment.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions