Skip to content

Delete openshift-logging operator group#2140

Merged
kovayur merged 1 commit intomainfrom
remove-operator-group
Jan 7, 2025
Merged

Delete openshift-logging operator group#2140
kovayur merged 1 commit intomainfrom
remove-operator-group

Conversation

@kovayur
Copy link
Copy Markdown
Contributor

@kovayur kovayur commented Jan 7, 2025

Description

Problem

OperatorGroup can't be added to the dp-terraform Helm chart, because it seems like it is created on OSD clusters by default and can't be managed (owned) by helm:

{"level":"error","ts":"2025-01-07T11:59:06Z","logger":"helm.controller","msg":"Failed to sync release","namespace":"rhacs","name":"rhacs-terraform","apiVersion":"cloud.stackrox.io/v1alpha1","kind":"Fleetshard","release":"rhacs-terraform","error":"failed to get candidate release: rendered manifests contain a resource that already exists. Unable to continue with update: OperatorGroup \"openshift-logging\" in namespace \"openshift-logging\" exists and cannot be imported into the current release: invalid ownership metadata; label validation error: missing key \"app.kubernetes.io/managed-by\": must be set to \"Helm\"; annotation validation error: missing key \"meta.helm.sh/release-name\": must be set to \"rhacs-terraform\"; annotation validation error: missing key \"meta.helm.sh/release-namespace\": must be set to \"rhacs\"","stacktrace":"github.com/operator-framework/operator-sdk/internal/helm/controller.HelmOperatorReconciler.Reconcile\n\toperator-sdk/internal/helm/controller/reconcile.go:219\nsigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Reconcile\n\toperator-sdk/vendor/sigs.k8s.io/controller-runtime/pkg/internal/controller/controller.go:122\nsigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).reconcileHandler\n\toperator-sdk/vendor/sigs.k8s.io/controller-runtime/pkg/internal/controller/controller.go:323\nsigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).processNextWorkItem\n\toperator-sdk/vendor/sigs.k8s.io/controller-runtime/pkg/internal/controller/controller.go:274\nsigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Start.func2.2\n\toperator-sdk/vendor/sigs.k8s.io/controller-runtime/pkg/internal/controller/controller.go:235"}

On the other hand, the operator is not installed on ROSA clusters and OperatorGroup is required when you install an operator with manifests (kubectl, helm).

Proposed solution

Move the problematic OperatorGroup to an ArgoCD application for ROSA clusters.

Checklist (Definition of Done)

  • Unit and integration tests added
  • Added test description under Test manual
  • Documentation added if necessary (i.e. changes to dev setup, test execution, ...)
  • CI and all relevant tests are passing
  • Add the ticket number to the PR title if available, i.e. ROX-12345: ...
  • Discussed security and business related topics privately. Will move any security and business related topics that arise to private communication channel.
  • Add secret to app-interface Vault or Secrets Manager if necessary
  • RDS changes were e2e tested manually
  • Check AWS limits are reasonable for changes provisioning new resources
  • (If applicable) Changes to the dp-terraform Helm values have been reflected in the addon on integration environment

Test manual

TODO: Add manual testing efforts

# To run tests locally run:
make db/teardown db/setup db/migrate
make ocm/setup
make verify lint binary test test/integration

@openshift-ci openshift-ci bot added the approved label Jan 7, 2025
@kovayur kovayur requested a review from kurlov January 7, 2025 13:34
@openshift-ci
Copy link
Copy Markdown
Contributor

openshift-ci bot commented Jan 7, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: kovayur, kurlov

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kovayur
Copy link
Copy Markdown
Contributor Author

kovayur commented Jan 7, 2025

Most likely the operator group on OSD is defined here: https://github.com/openshift/managed-cluster-config/blob/master/deploy/osd-logging/01-operatorgroup.yaml

@kovayur kovayur merged commit fdf2f4c into main Jan 7, 2025
@kovayur kovayur deleted the remove-operator-group branch January 7, 2025 15:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants