Skip to content

Investigate usage of pebble notices for admin UI syncing #262

@nsklikas

Description

@nsklikas

Enhancement Proposal

When the admin UI makes some change in the configMaps used to create the kratos config, we need to wait for the kratos charm to re-render the config file. This will happen when an event is fired (update-status), the problem is that we can't be sure when that is going to be fired. We need to find a way to make the changes applied faster.

Ideally we should look into using pebble notices. Since we can't trigger a pebble notice from the admin UI app on the kratos charm (need to verify this), we will need to trigger a pebble notice from the admin UI app that will cause the admin UI charm to change something in a relation with the kratos charm which will cause the charm to re-render the config file.

Another approach would be to create a go script (or python), that we would inject in the kratos container. This script would watch for changes in the providers or identity_schemas configmap and it would trigger a pebble notice to notify the charm to re-render the config file. This will save us the trouble of having to use juju integrations, but it is hacky.

As a stopgap solution we can just implement an action in the kratos charm that would re-render the config file and apply it in the kratos container. The admin UI will have to simply show the user a pop-up saying that they should run this action to make kratos peek up the changes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions