-
Bug
-
Resolution: Done
-
Undefined
-
1.9.0
-
False
-
-
False
-
-
Known Issue
-
Done
-
-
Description of problem:
When running the mirror-plugins.sh script to mirror a full plugin catalog index image, it currently rebuilds that catalog index image after replacing all plugin OCI references to their mirrored ones.
When a user later tries to use that mirrored catalog index image in their Backstage CR in their disconnected environment, the init container will fail to start with an error like this, even if the user did not declare any plugin reference to registry.access.redhat.com:
InstallException: Cannot use {{inherit}} for oci://registry.access.redhat.com/rhdh/red-hat-developer-hub-backstage-plugin-orchestrator: no existing plugin configuration found. Ensure a plugin from this image is defined in an included file with an explicit version.
Root cause
Those registry.access.redhat.com refs are declared in the operator default config (but disabled by default), and later merged by the Operator at runtime with the user-provided dynamic-plugins ConfigMap when it reconciles the CR.
Now the problem is that the install-dynamic-plugins resolves the OCI references and attempts to merge plugin configs even on disabled plugins, as reported in RHDHBUGS-2533 (related Slack thread).
This issue only affects Operator-backed instances of RHDH.
Workaround
Manually edit the Operator's default config ConfigMap in the cluster: called `rhdh-default-config` in the `rhdh-operator` namespace.
Locate the `dynamic-plugins.yaml` key in that ConfigMap and make the default `plugins` list empty, as shown in the example below. Then wait a few seconds until the changes are automatically propagated to the Operator pod.
# -- Truncated -- dynamic-plugins.yaml: | apiVersion: v1 kind: ConfigMap metadata: name: default-dynamic-plugins data: dynamic-plugins.yaml: | includes: - dynamic-plugins.default.yaml ### TODO: You would need to edit the "plugins" field below: plugins: [] # -- Truncated --
Notes
- RHDHBUGS-2649 should help address this by no longer rebuilding the plugin catalog index image. As part of the airgapping procedure, it would be up to the user to explicitly mount a standard registries.conf extra file into the init container with their own mirroring rules, so that they can benefit from transparent mirroring of the plugin refs.
- is caused by
-
RHDHPLAN-253 Implement solution for mirroring OCI artifacts into an airgapped RHDH deployment
-
- Release Pending
-
- relates to
-
RHDHBUGS-2533 install-dynamic-plugins.py should check disabled overrides before resolving OCI references
-
- New
-
-
RHDHBUGS-2649 Plugin mirroring script should avoid rebuilding the catalog index image
-
- In Progress
-