Trusted certificate authorities in the form

Status: Implemented Issue: https://gitlab.com/gitlab-org/cloud-native/gitlab-operator/-/work_items/2262 Parent: GitLab instance form

Goal

An administrator manages the certificate authorities GitLab trusts in the Bridge form, and sees beside them the certificate authorities the Operator adds on its own, so that they know what GitLab trusts without reading the resource.

Requirements

  • A section for trusted certificate authorities follows Networking. It edits spec.certificates.customCAs, as Trusted certificate authorities defines.
  • Each entry takes a source, Secret or ConfigMap, a name, and optional keys. Entries can be added and removed. A form with no entry leaves the field unset.
  • An entry without a name, with a name that is not a valid resource name, or with a key that is not a valid key, fails validation. So does a key that two entries share.
  • A second list shows the certificate authorities the Operator manages, from status.managedCAs: the source, the subject, and the expiry. It is read-only, and the auto-refresh updates it without touching the entries.
  • With no CA managed, the list says so, and says that the Operator adds the CA of an Orbit that serves TLS.
  • When the saved spec.chart.values set global.certificates.customCAs, the section warns that they replace the entries, and that the certificate authorities the Operator manages still apply.

Out of scope

  • Creating the Secret or the ConfigMap of an entry.
  • Showing the subject or the expiry of an entry of the administrator’s own, which would need Bridge to read the Secret.

FAQ

  • Why are the certificate authorities of the Operator read-only? The Operator derives them from the resources the instance references, and writes them on every pass. An edit would be undone within 30 seconds.