gardener / dashboard

Web-based GUI for Gardener installations.
Apache License 2.0
208 stars 103 forks source link

Access Restriction Feature: Reliability Issues and Proposed Solution #2120

Open grolu opened 1 month ago

grolu commented 1 month ago

Current Situation

The current access restriction feature is no longer functioning reliably due to recent changes in Gardener.

Proposed Solution

To address these issues, Gardener must become aware of access restrictions to ensure they are enforced when activated for a shoot. A client-side-only solution is no longer sufficient.

Instead of (mis)using the seedSelector, we propose the following:

  1. Introduce a new attribute to the shoot spec or utilize a label controlled by Gardener to enforce access restrictions.

  2. For new shoots:

    • Gardener should ensure that the selected seed complies with the access restriction requirements (similar to how the seedSelector works).
  3. For existing shoots:

    • Access restrictions can only be set if the current seed meets the requirements. If not, an error should be returned, instructing the user to migrate the control plane to a compliant seed.
    • Control plane migration should only be allowed if the new seed meets the access restriction requirements. If not, an error should inform the user that the new seed does not comply with the access restrictions.
  4. Shoot Workload:

    • Access restrictions can only be set if the shoot region meets the requirements. To check this, a label is added to the region in the cloudprofile (like we already do). Gardener must ensure that the region has the correct label. If not an error should inform the user that the region does not comply with the access restrictions.

The exact changes to the shoot spec are still under discussion. Additionally, we need to clarify how to handle existing shoots and clusters currently in an unsupported state (i.e., those on seeds that do not meet access restriction requirements).

Tasks

rfranzke commented 1 month ago

/assign