Documentation ¶
Overview ¶
The update package manages logic related to automatic updates.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetLatestMicro ¶
GetLatestMicro returns the most recent image tag within a minor (the "y" in "x.y.z"). If the minor was not found or if we never managed to fetch any tags, the second return value is false.
func GetLatestMinor ¶
GetLatestMinor returns the most recent minor (the "y" in "x.y.z"). If there were issues fetching the tags it returns an error.
func HandleUpdate ¶
func HandleUpdate(nexus *v1alpha1.Nexus, deployed, required *appsv1.Deployment, scheme *runtime.Scheme, c client.Client) error
HandleUpdate constructs state from 'nexus.status.updateConditions' and, based on this state, it may:
- mark an update as started
- mark an update as finished
If an update fails automatic updates are disabled and the image is set to the previously deployed tag
This is a state machine with two states: "idle" and "updating". "idle" transitions into "updating" if isNewUpdate == true. "updating" transitions back to "idle" if automatic updates get disabled or if the update fails/succeeds. "updating" transitions to itself if isNewUpdate == true.
func HigherVersion ¶
HigherVersion checks if thisTag is of a higher version than otherTag
Types ¶
This section is empty.