Skip to content

Implement mechanism to allow for regular reconciliation of initilisation logic #175

@aaronschweig

Description

@aaronschweig

Current Situation

At the moment we have quite an extensive initialiser for organizational accounts that takes care of a multitude of things, e.g.

  • creating a Store
  • setting up and configuring a Realm in keycloak
  • creating a WorkspaceAuthenticationConfiguration for the new organization
  • creating an Invite resource for the first user of that org

All of these things are fire and forget - meaning they are configured and created once and updates can never reach them in case some logic changes or some default central configuration needs to be adjusted.

We need to change that behaviour and introduce a new controller that reconciles accounts (ideally only the ones that the initialiser reconciles) and reconcile them using the same logic that the initialiser has.

Meaning in our target picture we need to ensure that

  • The subroutines used in the initialiser are idempotent and are able to properly perform there work on already existing entities
  • Create a new controller with a filter that reconciles accounts that are affected by the initialiser (here multiple ways can lead to the same goal. One could think of a labelselector that matches a label the initialiser sets or a predicate that works directly on the received object and filters them)
  • Reuse the subroutines in that new controller to roll out future changes more easily
  • Make sure the new controller DOES NOT INTERFERE with the initialiser during the first run.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions