cowboysysop / charts

Cowboy Sysop Charts
MIT License
116 stars 70 forks source link

Support for custom labels on ClusterRole resources #561

Closed odise closed 11 months ago

odise commented 11 months ago

I would like to add some dedicated labels on the ClusterRole resources deployed with the vertical-pod-autoscaler chart.

Here is an example:

apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
  labels:
    rbac.authorization.k8s.io/aggregate-to-admin: "true"
    rbac.authorization.k8s.io/aggregate-to-edit: "true"
  name: vertical-pod-autoscaler-vertical-pod-autoscaler-recommender
rules:
  ...

If you want me to provide a PR, don't hesitate to give me a wink. Thanks a bunch.

sebastien-prudhomme commented 11 months ago

I'm not fan of doing this because the cluster roles in the chart are intended for the VPA components not for people or other applications.

If you want to give access to VPA custom ressources, you can use the extraDeploy value to create a new cluster role that will have the labels you want.