-
Notifications
You must be signed in to change notification settings - Fork 95
Fix: Move away from kube-rbac-proxy sidecar for metric server auth. #605
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
codeknight03
wants to merge
3
commits into
meshery:master
Choose a base branch
from
codeknight03:kramwani/fix-kube-rbac-proxy-dep
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
d1d361f
fix(metrics): move metrics auth to container runtime instead of sidecar.
codeknight03 49fee49
fix(metrics-auth): remove all refs to kube-rbac-proxy in default config.
codeknight03 7d0dfee
chore(bundle): new bundle version for auth changes to metric endpoint.
codeknight03 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
bundle/0.0.2/manifests/meshery-metrics-reader_rbac.authorization.k8s.io_v1_clusterrole.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
kind: ClusterRole | ||
metadata: | ||
creationTimestamp: null | ||
name: meshery-metrics-reader | ||
rules: | ||
- nonResourceURLs: | ||
- /metrics | ||
verbs: | ||
- get |
229 changes: 229 additions & 0 deletions
229
bundle/0.0.2/manifests/meshery-operator.clusterserviceversion.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,229 @@ | ||
apiVersion: operators.coreos.com/v1alpha1 | ||
kind: ClusterServiceVersion | ||
metadata: | ||
annotations: | ||
alm-examples: |- | ||
[ | ||
{ | ||
"apiVersion": "meshery.io/v1alpha1", | ||
"kind": "Broker", | ||
"metadata": { | ||
"annotations": { | ||
"meshery/component-type": "management-plane" | ||
}, | ||
"labels": { | ||
"app": "meshery", | ||
"component": "controller", | ||
"version": "v0.1.15" | ||
}, | ||
"name": "meshery-meshery-broker", | ||
"namespace": "meshery" | ||
}, | ||
"spec": { | ||
"size": 1 | ||
} | ||
}, | ||
{ | ||
"apiVersion": "meshery.io/v1alpha1", | ||
"kind": "MeshSync", | ||
"metadata": { | ||
"annotations": { | ||
"meshery/component-type": "management-plane" | ||
}, | ||
"labels": { | ||
"app": "meshery", | ||
"component": "controller", | ||
"version": "v0.1.15" | ||
}, | ||
"name": "meshery-meshery-meshsync", | ||
"namespace": "meshery" | ||
}, | ||
"spec": { | ||
"broker": { | ||
"native": { | ||
"name": "meshery-broker", | ||
"namespace": "meshery" | ||
} | ||
}, | ||
"size": 1, | ||
"watch-list": { | ||
"apiVersion": "v1", | ||
"data": { | ||
"whitelist": "[{\"Resource\":\"namespaces.v1.\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"configmaps.v1.\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"nodes.v1.\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"secrets.v1.\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"persistentvolumes.v1.\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"persistentvolumeclaims.v1.\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"replicasets.v1.apps\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"pods.v1.\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"services.v1.\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"deployments.v1.apps\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"statefulsets.v1.apps\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"daemonsets.v1.apps\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"ingresses.v1.networking.k8s.io\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"endpoints.v1.\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"endpointslices.v1.discovery.k8s.io\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"cronjobs.v1.batch\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"replicationcontrollers.v1.\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"storageclasses.v1.storage.k8s.io\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"clusterroles.v1.rbac.authorization.k8s.io\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"volumeattachments.v1.storage.k8s.io\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]},{\"Resource\":\"apiservices.v1.apiregistration.k8s.io\",\"Events\":[\"ADDED\",\"MODIFIED\",\"DELETED\"]}]" | ||
} | ||
} | ||
} | ||
} | ||
] | ||
capabilities: Basic Install | ||
createdAt: "2025-04-06T19:51:04Z" | ||
operators.operatorframework.io/builder: operator-sdk-v1.39.2 | ||
operators.operatorframework.io/project_layout: go.kubebuilder.io/v4 | ||
name: meshery-operator.v0.0.2 | ||
namespace: placeholder | ||
spec: | ||
apiservicedefinitions: {} | ||
customresourcedefinitions: | ||
owned: | ||
- kind: Broker | ||
name: brokers.meshery.io | ||
version: v1alpha1 | ||
- description: MeshSync is the Schema for the meshsyncs API | ||
displayName: Mesh Sync | ||
kind: MeshSync | ||
name: meshsyncs.meshery.io | ||
version: v1alpha1 | ||
description: Meshery Operator is the multi-service mesh operator and implementation | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. meshery-operator is more than a multi-service |
||
of MeshSync. | ||
displayName: meshery-operator | ||
icon: | ||
- base64data: "" | ||
mediatype: "" | ||
install: | ||
spec: | ||
clusterPermissions: | ||
- rules: | ||
- apiGroups: | ||
- '*' | ||
resources: | ||
- '*' | ||
verbs: | ||
- create | ||
- delete | ||
- get | ||
- list | ||
- patch | ||
- update | ||
- watch | ||
- apiGroups: | ||
- authentication.k8s.io | ||
resources: | ||
- tokenreviews | ||
verbs: | ||
- create | ||
- apiGroups: | ||
- authorization.k8s.io | ||
resources: | ||
- subjectaccessreviews | ||
verbs: | ||
- create | ||
- apiGroups: | ||
- meshery.io | ||
resources: | ||
- brokers | ||
verbs: | ||
- create | ||
- delete | ||
- get | ||
- list | ||
- patch | ||
- update | ||
- watch | ||
- apiGroups: | ||
- meshery.io | ||
resources: | ||
- brokers/status | ||
verbs: | ||
- get | ||
- patch | ||
- update | ||
serviceAccountName: meshery-operator | ||
deployments: | ||
- label: | ||
app: meshery | ||
component: operator | ||
name: meshery-operator | ||
spec: | ||
replicas: 1 | ||
selector: | ||
matchLabels: | ||
app: meshery | ||
component: operator | ||
strategy: {} | ||
template: | ||
metadata: | ||
labels: | ||
app: meshery | ||
component: operator | ||
spec: | ||
containers: | ||
- args: | ||
- --enable-leader-election | ||
# Default Args | ||
# ---metrics-bind-address=:8443 | ||
# ---secure-metrics=true | ||
command: | ||
- /manager | ||
image: layer5/meshery-operator:stable-latest | ||
imagePullPolicy: Always | ||
name: manager | ||
ports: | ||
- containerPort: 9443 | ||
hostPort: 9443 | ||
name: server | ||
- containerPort: 8443 | ||
hostPort: 8443 | ||
name: metrics | ||
resources: | ||
limits: | ||
cpu: 100m | ||
memory: 30Mi | ||
requests: | ||
cpu: 100m | ||
memory: 20Mi | ||
serviceAccountName: meshery-operator | ||
terminationGracePeriodSeconds: 10 | ||
permissions: | ||
- rules: | ||
- apiGroups: | ||
- "" | ||
resources: | ||
- configmaps | ||
verbs: | ||
- get | ||
- list | ||
- watch | ||
- create | ||
- update | ||
- patch | ||
- delete | ||
- apiGroups: | ||
- "" | ||
resources: | ||
- configmaps/status | ||
verbs: | ||
- get | ||
- update | ||
- patch | ||
- apiGroups: | ||
- "" | ||
resources: | ||
- events | ||
verbs: | ||
- create | ||
- patch | ||
serviceAccountName: meshery-operator | ||
strategy: deployment | ||
installModes: | ||
- supported: false | ||
type: OwnNamespace | ||
- supported: false | ||
type: SingleNamespace | ||
- supported: false | ||
type: MultiNamespace | ||
- supported: true | ||
type: AllNamespaces | ||
keywords: | ||
- servicemesh | ||
- meshSync | ||
links: | ||
- name: Meshery Operator | ||
url: https://meshery-operator.domain | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. not sure this is a valid url |
||
maintainers: | ||
- email: [email protected] | ||
name: aisuko | ||
maturity: alpha | ||
provider: | ||
name: meshery | ||
url: https://github.com/meshery | ||
version: 0.0.2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,95 @@ | ||
apiVersion: apiextensions.k8s.io/v1 | ||
kind: CustomResourceDefinition | ||
metadata: | ||
annotations: | ||
controller-gen.kubebuilder.io/version: v0.17.1 | ||
creationTimestamp: null | ||
name: brokers.meshery.io | ||
spec: | ||
group: meshery.io | ||
names: | ||
kind: Broker | ||
listKind: BrokerList | ||
plural: brokers | ||
singular: broker | ||
scope: Namespaced | ||
versions: | ||
- name: v1alpha1 | ||
schema: | ||
openAPIV3Schema: | ||
description: Broker is the Schema for the brokers API | ||
properties: | ||
apiVersion: | ||
description: |- | ||
APIVersion defines the versioned schema of this representation of an object. | ||
Servers should convert recognized schemas to the latest internal value, and | ||
may reject unrecognized values. | ||
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources | ||
type: string | ||
kind: | ||
description: |- | ||
Kind is a string value representing the REST resource this object represents. | ||
Servers may infer this from the endpoint the client submits requests to. | ||
Cannot be updated. | ||
In CamelCase. | ||
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds | ||
type: string | ||
metadata: | ||
type: object | ||
spec: | ||
description: BrokerSpec defines the desired state of Broker | ||
properties: | ||
size: | ||
format: int32 | ||
type: integer | ||
type: object | ||
status: | ||
description: BrokerStatus defines the observed state of Broker | ||
properties: | ||
conditions: | ||
items: | ||
properties: | ||
lastProbeTime: | ||
format: date-time | ||
type: string | ||
lastTransitionTime: | ||
format: date-time | ||
type: string | ||
message: | ||
type: string | ||
observedGeneration: | ||
format: int64 | ||
type: integer | ||
reason: | ||
type: string | ||
status: | ||
type: string | ||
type: | ||
type: string | ||
required: | ||
- lastTransitionTime | ||
- message | ||
- reason | ||
- status | ||
- type | ||
type: object | ||
type: array | ||
endpoint: | ||
properties: | ||
external: | ||
type: string | ||
internal: | ||
type: string | ||
type: object | ||
type: object | ||
type: object | ||
served: true | ||
storage: true | ||
subresources: | ||
status: {} | ||
status: | ||
acceptedNames: | ||
kind: "" | ||
plural: "" | ||
conditions: null | ||
storedVersions: null |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this changes looks more than a patch. it should be a major upgrade or at least minor one ?