Charmed-Kubernetes/kubeapi-load-balancer/hooks/relations/tls-certificates/docs/common.md

1.4 KiB

CertificateRequest

CertificateRequest(self, unit, cert_type, cert_name, common_name, sans)

application_name

Name of the application which the request came from.

:returns: Name of application :rtype: str

cert

The cert published for this request, if any.

cert_type

Type of certificate, 'server' or 'client', being requested.

resolve_unit_name

CertificateRequest.resolve_unit_name(unit)

Return name of unit associated with this request.

unit_name should be provided in the relation data to ensure compatability with cross-model relations. If the unit name is absent then fall back to unit_name attribute of the unit associated with this request.

:param unit: Unit to extract name from :type unit: charms.reactive.endpoints.RelatedUnit :returns: Name of unit :rtype: str

Certificate

Certificate(self, cert_type, common_name, cert, key)

Represents a created certificate and key.

The cert_type, common_name, cert, and key values can be accessed either as properties or as the contents of the dict.