Manage resource Ready conditions and track managed resources status

Use kstatus to track various resources that are created, and aggregate the status of these various resources to determine if suRelease is properly reconciled or not. Update observedGeneration only if suRelease id Ready.

Here is an example of the status of suRelease when sylva-units HelmRelease is not Ready

status:
  conditions:
  - lastTransitionTime: "2023-12-13T08:56:02Z"
    message: Some resources are not Ready
    observedGeneration: 1
    reason: ResourceNotReady
    status: "False"
    type: Ready
  observedGeneration: -1
  resourcesStatus:
  - kind: GitRepository
    name: testrelease
    status: Resource is Ready
  - kind: HelmRelease
    name: testrelease
    status: InProgress - install retries exhausted

The agreggation of managed resources status in resourcesStatus will we helpfull once we'll also have to manage gitRepos, ociRepositories, gitRepositories, aso...

Closes #9 (closed)

Edited by Francois Eleouet

Merge request reports

Loading