Skip to content
Merged
Show file tree
Hide file tree
Changes from 8 commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
ececb06
Migration of kube-rbac-proxy in gitops-operator
akhilnittala Apr 8, 2026
0b7f0f0
Migration of kube-rbac-proxy in gitops-operator
akhilnittala Apr 8, 2026
698bc5b
Migration of kube-rbac-proxy in gitops-operator
akhilnittala Apr 8, 2026
d21c451
Migration of kube-rbac-proxy in gitops-operator
akhilnittala Apr 9, 2026
c297414
Migration of kube-rbac-proxy in gitops-operator
akhilnittala Apr 9, 2026
cf3fa3e
Migration of kube-rbac-proxy in gitops-operator
akhilnittala Apr 9, 2026
de42adc
Migration of kube-rbac-proxy in gitops-operator
akhilnittala Apr 13, 2026
c19caa6
Migration of kube-rbac-proxy in gitops-operator
akhilnittala Apr 14, 2026
95c1da4
Merge branch 'master' into usr/akhil/GITOPS-9256
akhilnittala Apr 15, 2026
9090b7f
Migration of kube-rbac-proxy in gitops-operator
akhilnittala Apr 15, 2026
efbfd9d
Migration of kube-rbac-proxy in gitops-operator
akhilnittala Apr 15, 2026
cad0ecb
Migration of kube-rbac-proxy in gitops-operator
akhilnittala Apr 15, 2026
d55e276
Migration of kube-rbac-proxy in gitops-operator
akhilnittala Apr 15, 2026
a91a821
Merge branch 'master' into usr/akhil/GITOPS-9256
akhilnittala Apr 16, 2026
da9d229
Merge branch 'master' into usr/akhil/GITOPS-9256
akhilnittala Apr 20, 2026
de73536
Migration of kube-rbac-proxy in gitops-operator
akhilnittala Apr 20, 2026
d9bb509
Migration of kube-rbac-proxy in gitops-operator
akhilnittala Apr 21, 2026
5800af1
Migration of kube-rbac-proxy in gitops-operator
akhilnittala Apr 21, 2026
1250dc0
Merge branch 'master' into usr/akhil/GITOPS-9256
akhilnittala Apr 22, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 1 addition & 31 deletions bundle/manifests/gitops-operator.clusterserviceversion.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ metadata:
capabilities: Deep Insights
console.openshift.io/plugins: '["gitops-plugin"]'
containerImage: quay.io/redhat-developer/gitops-operator
createdAt: "2026-04-09T19:32:55Z"
createdAt: "2026-04-13T13:27:20Z"
description: Enables teams to adopt GitOps principles for managing cluster configurations
and application delivery across hybrid multi-cluster Kubernetes environments.
features.operators.openshift.io/disconnected: "true"
Expand Down Expand Up @@ -899,36 +899,6 @@ spec:
- ALL
readOnlyRootFilesystem: true
runAsNonRoot: true
- args:
- --secure-listen-address=0.0.0.0:8443
- --upstream=http://127.0.0.1:8080
- --tls-cert-file=/etc/tls/private/tls.crt
- --tls-private-key-file=/etc/tls/private/tls.key
- --logtostderr=true
- --allow-paths=/metrics
- --http2-disable
image: registry.redhat.io/openshift4/ose-kube-rbac-proxy:v4.15
name: kube-rbac-proxy
ports:
- containerPort: 8443
name: metrics
protocol: TCP
resources:
limits:
cpu: 500m
memory: 128Mi
requests:
cpu: 1m
memory: 15Mi
securityContext:
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
volumeMounts:
- mountPath: /etc/tls/private
name: kube-rbac-proxy-tls
readOnly: true
securityContext:
runAsNonRoot: true
serviceAccountName: openshift-gitops-operator-controller-manager
Expand Down
6 changes: 4 additions & 2 deletions cmd/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ import (
"github.com/redhat-developer/gitops-operator/controllers/argocd/openshift"
"github.com/redhat-developer/gitops-operator/controllers/util"
k8sruntime "k8s.io/apimachinery/pkg/runtime"
"sigs.k8s.io/controller-runtime/pkg/metrics/filters"
metricsserver "sigs.k8s.io/controller-runtime/pkg/metrics/server"
//+kubebuilder:scaffold:imports
)
Expand Down Expand Up @@ -148,8 +149,9 @@ func main() {
webhookServer := webhook.NewServer(webhookServerOptions)

metricsServerOptions := metricsserver.Options{
BindAddress: metricsAddr,
TLSOpts: []func(*tls.Config){disableHTTP2},
BindAddress: metricsAddr,
TLSOpts: []func(*tls.Config){disableHTTP2},
FilterProvider: filters.WithAuthenticationAndAuthorization,
}

// Set default manager options
Expand Down
9 changes: 5 additions & 4 deletions config/default/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,12 @@ bases:
# [PROMETHEUS] To enable prometheus monitor, uncomment all sections with 'PROMETHEUS'.
- ../prometheus

# Protect the /metrics endpoint with controller-runtime authn/authz.
# If you comment out manager_metrics_patch.yaml, also comment out metrics_service.yaml,
# metrics_role.yaml, metrics_role_binding.yaml, and metrics_reader_clusterrole.yaml
# in ../rbac/kustomization.yaml so the metrics Service is disabled as well.
patchesStrategicMerge:
# Protect the /metrics endpoint by putting it behind auth.
# If you want your controller-manager to expose the /metrics
# endpoint w/o any authn/z, please comment the following line.
- manager_auth_proxy_patch.yaml
- manager_metrics_patch.yaml

# Mount the controller config file for loading manager configurations
# through a ComponentConfig type
Expand Down
57 changes: 0 additions & 57 deletions config/default/manager_auth_proxy_patch.yaml

This file was deleted.

28 changes: 28 additions & 0 deletions config/default/manager_metrics_patch.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# This patch configures the manager to serve metrics securely using
# controller-runtime's built-in authn/authz (replacing the deprecated
# kube-rbac-proxy sidecar).
apiVersion: apps/v1
kind: Deployment
metadata:
name: controller-manager
namespace: system
spec:
selector:
matchLabels:
control-plane: gitops-operator
template:
spec:
containers:
- name: manager
args:
- "--health-probe-bind-address=:8081"
- "--metrics-bind-address=127.0.0.1:8080"
Comment thread
akhilnittala marked this conversation as resolved.
Outdated
- "--leader-elect"
volumes:
# Secret created by the service CA operator.
# We assume that the Kubernetes service exposing the application's pods has the
# "service.beta.openshift.io/serving-cert-secret-name: kube-rbac-proxy-tls"
# annotation.
- name: kube-rbac-proxy-tls
secret:
secretName: kube-rbac-proxy-tls
Comment thread
akhilnittala marked this conversation as resolved.
Outdated
15 changes: 8 additions & 7 deletions config/rbac/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,11 @@ resources:
- role_binding.yaml
- leader_election_role.yaml
- leader_election_role_binding.yaml
# Comment the following 4 lines if you want to disable
# the auth proxy (https://github.com/brancz/kube-rbac-proxy)
# which protects your /metrics endpoint.
- auth_proxy_service.yaml
- auth_proxy_role.yaml
- auth_proxy_role_binding.yaml
# - auth_proxy_client_clusterrole.yaml
# These resources expose /metrics over HTTPS on port 8443 and grant the
# controller-runtime authn/authz permissions required by manager_metrics_patch.yaml.
# Comment these lines together with manager_metrics_patch.yaml if you want to
# disable secure metrics for the controller-manager.
- metrics_service.yaml
- metrics_role.yaml
- metrics_role_binding.yaml
# - metrics_reader_clusterrole.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: proxy-role
name: metrics-role
rules:
- nonResourceURLs:
- "/metrics"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
name: proxy-rolebinding
name: metrics-rolebinding
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: proxy-role
name: metrics-role
subjects:
- kind: ServiceAccount
name: controller-manager
Expand Down
File renamed without changes.
19 changes: 16 additions & 3 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ module github.com/redhat-developer/gitops-operator
go 1.25.5

require (
github.com/argoproj-labs/argo-rollouts-manager v0.0.8-0.20260224121037-1824164aac67
github.com/argoproj-labs/argo-rollouts-manager v0.0.9-0.20260410162909-2c47622e05c4
github.com/argoproj-labs/argocd-image-updater v1.1.1
github.com/argoproj-labs/argocd-operator v0.17.0-rc1.0.20260409105431-954fe0119f7e
github.com/argoproj-labs/argocd-operator v0.17.0-rc1.0.20260410174833-e8a74112682f
github.com/argoproj/argo-cd/v3 v3.3.6
github.com/argoproj/gitops-engine v0.7.1-0.20251217140045-5baed5604d2d
github.com/go-logr/logr v1.4.3
Expand All @@ -32,6 +32,7 @@ require (
)

require (
cel.dev/expr v0.25.1 // indirect
cloud.google.com/go/compute/metadata v0.9.0 // indirect
cyphar.com/go-pathrs v0.2.1 // indirect
dario.cat/mergo v1.0.2 // indirect
Expand All @@ -44,6 +45,7 @@ require (
github.com/Masterminds/semver/v3 v3.4.0 // indirect
github.com/Microsoft/go-winio v0.6.2 // indirect
github.com/ProtonMail/go-crypto v1.1.6 // indirect
github.com/antlr4-go/antlr/v4 v4.13.1 // indirect
github.com/argoproj/pkg v0.13.7-0.20250305113207-cbc37dc61de5 // indirect
github.com/argoproj/pkg/v2 v2.0.1 // indirect
github.com/beorn7/perks v1.0.1 // indirect
Expand Down Expand Up @@ -93,6 +95,7 @@ require (
github.com/golang/groupcache v0.0.0-20241129210726-2c02b8208cf8 // indirect
github.com/golang/protobuf v1.5.4 // indirect
github.com/google/btree v1.1.3 // indirect
github.com/google/cel-go v0.26.0 // indirect
github.com/google/gnostic-models v0.7.1 // indirect
github.com/google/go-github/v69 v69.2.0 // indirect
github.com/google/go-github/v75 v75.0.0 // indirect
Expand All @@ -102,6 +105,7 @@ require (
github.com/gregjones/httpcache v0.0.0-20190611155906-901d90724c79 // indirect
github.com/grpc-ecosystem/go-grpc-middleware/v2 v2.3.3 // indirect
github.com/grpc-ecosystem/grpc-gateway v1.16.0 // indirect
github.com/grpc-ecosystem/grpc-gateway/v2 v2.27.2 // indirect
github.com/hashicorp/go-cleanhttp v0.5.2 // indirect
github.com/hashicorp/go-retryablehttp v0.7.8 // indirect
github.com/inconshreveable/mousetrap v1.1.0 // indirect
Expand Down Expand Up @@ -136,7 +140,7 @@ require (
github.com/prometheus/common v0.66.1 // indirect
github.com/prometheus/procfs v0.17.0 // indirect
github.com/r3labs/diff/v3 v3.0.2 // indirect
github.com/redis/go-redis/v9 v9.8.0 // indirect
github.com/redis/go-redis/v9 v9.18.0 // indirect
github.com/robfig/cron/v3 v3.0.2-0.20210106135023-bc59245fe10e // indirect
github.com/russross/blackfriday/v2 v2.1.0 // indirect
github.com/sergi/go-diff v1.4.0 // indirect
Expand All @@ -145,6 +149,7 @@ require (
github.com/skeema/knownhosts v1.3.1 // indirect
github.com/spf13/cobra v1.10.2 // indirect
github.com/spf13/pflag v1.0.10 // indirect
github.com/stoewer/go-strcase v1.3.1 // indirect
github.com/vmihailenco/go-tinylfu v0.2.2 // indirect
github.com/vmihailenco/msgpack/v5 v5.4.1 // indirect
github.com/vmihailenco/tagparser/v2 v2.0.0 // indirect
Expand All @@ -153,13 +158,20 @@ require (
github.com/xlab/treeprint v1.2.0 // indirect
go.opentelemetry.io/auto/sdk v1.2.1 // indirect
go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.63.0 // indirect
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.61.0 // indirect
go.opentelemetry.io/otel v1.40.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.38.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.38.0 // indirect
go.opentelemetry.io/otel/metric v1.40.0 // indirect
go.opentelemetry.io/otel/sdk v1.40.0 // indirect
go.opentelemetry.io/otel/trace v1.40.0 // indirect
go.opentelemetry.io/proto/otlp v1.7.1 // indirect
go.uber.org/atomic v1.11.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
go.yaml.in/yaml/v2 v2.4.3 // indirect
go.yaml.in/yaml/v3 v3.0.4 // indirect
golang.org/x/crypto v0.49.0 // indirect
golang.org/x/exp v0.0.0-20250718183923-645b1fa84792 // indirect
golang.org/x/net v0.52.0 // indirect
golang.org/x/oauth2 v0.35.0 // indirect
golang.org/x/sync v0.20.0 // indirect
Expand Down Expand Up @@ -189,6 +201,7 @@ require (
k8s.io/kubectl v0.34.0 // indirect
k8s.io/kubernetes v1.34.2 // indirect
oras.land/oras-go/v2 v2.6.0 // indirect
sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.33.0 // indirect
sigs.k8s.io/gateway-api v1.5.0 // indirect
sigs.k8s.io/json v0.0.0-20250730193827-2d320260d730 // indirect
sigs.k8s.io/kustomize/api v0.21.0 // indirect
Expand Down
Loading
Loading