GitLabCore versions

Status: Proposed Issue: https://gitlab.com/gitlab-org/cloud-native/gitlab-operator/-/work_items/2369 Parent: Release versions

Goal

An administrator sets a GitLab version, or a channel of GitLab versions, on a GitLabCore, and reads back the GitLab version it runs. A chart version is named only to override the manifest.

Requirements

  • spec.version of a GitLabCore selects a GitLab version for every type: version and versionRef of Static, minor of Patch, and major of Latest, Previous, and OldestSupported are GitLab versions.
  • A Static version takes exactly one of version, versionRef, and chartVersion. A chartVersion runs that GitLab chart version without reading the manifest, and is rejected on any other type.
  • The types that follow releases resolve against the releases the manifest index lists, and skip a release whose record has no gitlab-chart module.
  • A multi-minor upgrade steps through the newest release of each GitLab minor in between, each rendered from the chart of its record.
  • A version below the deployed one is refused: a lower GitLab version, or the same GitLab version with a lower chart.
  • status.version, status.targetVersion, status.availableVersion, status.rejectedVersion, and status.upgradeVersions report GitLab versions. status.chartVersion and status.targetChartVersion report the charts behind status.version and status.targetVersion. For a chartVersion, the GitLab version is the appVersion of the chart.
  • A Static GitLab version without a record, or with a record that lacks gitlab-chart, fails an instance with no target with Initialized=False and reason VersionUnresolved. An instance with a target keeps it, and reports Upgradeable=False with the same reason.
  • The bridge API and web UI read and write GitLab versions and chartVersion. The list shows the GitLab version an instance runs with the chart behind it, and the upgrade picker offers GitLab versions.

Out of scope

  • status.gitlabVersion, which status.version replaces.
  • Unattended major upgrades, downgrades, and rollbacks, which stay as Unattended upgrades states.
  • Converting resources that name chart versions in the fields that now take GitLab versions.

FAQ

  • When is a chart version named directly? For a chart-only fix ahead of the next release, a chart outside the manifest, or testing.
  • What happens to a resource that still names a chart version in version, minor, or major? It is read as a GitLab version. Chart majors (9, 10) and the GitLab majors the manifest records (18 and up) do not overlap, so it never resolves to another release: it reports VersionUnresolved. Move the value to chartVersion, or name the GitLab version.
  • Why compare the chart when the GitLab versions are equal? A chart-only release ships a newer chart for the same GitLab version. Naming that GitLab version after pinning the newer chart would otherwise render the older chart its record lists.