From cd7f977149563c0f087fef017173cab9afaf8a95 Mon Sep 17 00:00:00 2001 From: Tamal Saha Date: Sun, 17 Nov 2024 00:22:15 -0800 Subject: [PATCH] Impersonate api call to grafana dashboard Signed-off-by: Tamal Saha --- go.mod | 4 +- go.sum | 8 +-- pkg/graph/dashboard.go | 10 ++-- pkg/graph/pods.go | 2 +- pkg/graph/renderer.go | 54 ++++++++++--------- pkg/graph/setup.go | 43 +++++++++++---- pkg/registry/core/resourceservice/storage.go | 20 +++---- pkg/registry/meta/render/storage.go | 3 +- pkg/registry/meta/renderdashboard/storage.go | 2 +- pkg/registry/meta/resourcequery/storage.go | 4 +- .../kmodules.xyz/client-go/api/v1/cluster.go | 9 ++++ .../client-go/client/delegated.go | 44 +++++++++++---- .../apis/core/v1alpha1/openapi_generated.go | 12 +++++ .../identity/v1alpha1/openapi_generated.go | 6 +++ .../management/v1alpha1/openapi_generated.go | 6 +++ .../apis/meta/v1alpha1/openapi_generated.go | 18 +++++++ .../apis/shared/openapi_generated.go | 6 +++ .../resource-metadata/apis/shared/types.go | 5 +- .../apis/ui/v1alpha1/openapi_generated.go | 6 +++ ...appscode.com_resourceblockdefinitions.yaml | 2 + ....k8s.appscode.com_resourcedescriptors.yaml | 2 + ...meta.k8s.appscode.com_resourcelayouts.yaml | 10 ++++ ...eta.k8s.appscode.com_resourceoutlines.yaml | 10 ++++ ...i.k8s.appscode.com_resourcedashboards.yaml | 2 + .../clusterprofiles/ace/dbaas-generic.yaml | 1 + .../kubedb.com/v1/kubedb/elasticsearches.yaml | 2 + .../kubedb.com/v1/kubedb/kafkas.yaml | 1 + .../kubedb.com/v1/kubedb/mariadbs.yaml | 2 + .../kubedb.com/v1/kubedb/mongodbs.yaml | 2 + .../kubedb.com/v1/kubedb/mysqls.yaml | 2 + .../kubedb.com/v1/kubedb/perconaxtradbs.yaml | 2 + .../kubedb.com/v1/kubedb/pgbouncers.yaml | 2 + .../kubedb.com/v1/kubedb/postgreses.yaml | 2 + .../kubedb.com/v1/kubedb/proxysqls.yaml | 2 + .../kubedb.com/v1/kubedb/redises.yaml | 2 + .../v1alpha2/kubedb/clickhouses.yaml | 1 + .../kubedb.com/v1alpha2/kubedb/druids.yaml | 1 + .../v1alpha2/kubedb/elasticsearches.yaml | 2 + .../kubedb.com/v1alpha2/kubedb/ferretdbs.yaml | 1 + .../kubedb.com/v1alpha2/kubedb/kafkas.yaml | 1 + .../kubedb.com/v1alpha2/kubedb/mariadbs.yaml | 2 + .../kubedb.com/v1alpha2/kubedb/mongodbs.yaml | 2 + .../v1alpha2/kubedb/mssqlservers.yaml | 1 + .../kubedb.com/v1alpha2/kubedb/mysqls.yaml | 2 + .../kubedb.com/v1alpha2/kubedb/pgpool.yaml | 1 + .../v1alpha2/kubedb/postgreses.yaml | 2 + .../kubedb.com/v1alpha2/kubedb/proxysqls.yaml | 2 + .../kubedb.com/v1alpha2/kubedb/rabbitmqs.yaml | 1 + .../kubedb.com/v1alpha2/kubedb/redises.yaml | 2 + .../v1alpha2/kubedb/singlestores.yaml | 1 + .../kubedb.com/v1alpha2/kubedb/solrs.yaml | 1 + .../v1alpha2/kubedb/zookeepers.yaml | 1 + vendor/modules.txt | 4 +- 53 files changed, 264 insertions(+), 72 deletions(-) diff --git a/go.mod b/go.mod index 5a8b0613a2..f69e8663c3 100644 --- a/go.mod +++ b/go.mod @@ -47,12 +47,12 @@ require ( k8s.io/utils v0.0.0-20240502163921-fe8a2dddb1d0 kmodules.xyz/apiversion v0.2.0 kmodules.xyz/authorizer v0.29.1 - kmodules.xyz/client-go v0.30.37 + kmodules.xyz/client-go v0.30.38-0.20241117075231-750051a8f0b9 kmodules.xyz/custom-resources v0.30.0 kmodules.xyz/go-containerregistry v0.0.12 kmodules.xyz/monitoring-agent-api v0.30.2 kmodules.xyz/offshoot-api v0.30.1 - kmodules.xyz/resource-metadata v0.22.3-0.20241114091625-6c277c3fe863 + kmodules.xyz/resource-metadata v0.22.3-0.20241117093124-a5b36fb25424 kmodules.xyz/resource-metrics v0.30.5 kmodules.xyz/resource-metrics/utils v0.30.4 kmodules.xyz/sets v0.29.0 diff --git a/go.sum b/go.sum index 14c9504e4a..41973f54dd 100644 --- a/go.sum +++ b/go.sum @@ -927,8 +927,8 @@ kmodules.xyz/apiversion v0.2.0 h1:vAQYqZFm4xu4pbB1cAdHbFEPES6EQkcR4wc06xdTOWk= kmodules.xyz/apiversion v0.2.0/go.mod h1:oPX8g8LvlPdPX3Yc5YvCzJHQnw3YF/X4/jdW0b1am80= kmodules.xyz/authorizer v0.29.1 h1:uByGGoryKbZcfiEAhjcK/Y345I9mygNQP7DVpkMbNQQ= kmodules.xyz/authorizer v0.29.1/go.mod h1:kZRhclL8twzyt2bQuJQJbpYww2sc+qFr8I5PPoq/sWY= -kmodules.xyz/client-go v0.30.37 h1:hj4BMsNDgRVc2aDPB6Y3x5iCylXTZDZeQPJp/oA6lxs= -kmodules.xyz/client-go v0.30.37/go.mod h1:CAu+JlA8RVGtj6LQHu0Q1w2mnFUajuti49c7T1AvGdM= +kmodules.xyz/client-go v0.30.38-0.20241117075231-750051a8f0b9 h1:8qSZylUUBcY1rKlVLgm3mRjw3/mG8QT0tSuCCflmIeU= +kmodules.xyz/client-go v0.30.38-0.20241117075231-750051a8f0b9/go.mod h1:CAu+JlA8RVGtj6LQHu0Q1w2mnFUajuti49c7T1AvGdM= kmodules.xyz/crd-schema-fuzz v0.29.1 h1:zJTlWYOrT5dsVVHW8HGcnR/vaWfxQfNh11QwTtkYpcs= kmodules.xyz/crd-schema-fuzz v0.29.1/go.mod h1:n708z9YQqLMP2KNLQVgBcRJw1QpSWLvpNCEi+KJDOYE= kmodules.xyz/custom-resources v0.30.0 h1:vR3CbseHMLwR4GvtcJJuRuwIV8voKqFqNii27rMcm1o= @@ -939,8 +939,8 @@ kmodules.xyz/monitoring-agent-api v0.30.2 h1:sAgz5P5EXZqhlj1NzJ+QltAgeIx5bGSMj+a kmodules.xyz/monitoring-agent-api v0.30.2/go.mod h1:BoZFPDDRB7J39CcUsSDlzgW8PQCwik4ILPleyUob+Mg= kmodules.xyz/offshoot-api v0.30.1 h1:TrulAYO+oBsXe9sZZGTmNWIuI8qD2izMpgcTSPvgAmI= kmodules.xyz/offshoot-api v0.30.1/go.mod h1:T3mpjR6fui0QzOcmQvIuANytW48fe9ytmy/1cgx6D4g= -kmodules.xyz/resource-metadata v0.22.3-0.20241114091625-6c277c3fe863 h1:dfsQYd8Uk8iQ/kcwddhL8GNXTN/i8e6UB3C4t0ArwyM= -kmodules.xyz/resource-metadata v0.22.3-0.20241114091625-6c277c3fe863/go.mod h1:G57v46vQOq5P1HIs9Rl7lJ5Y4dBcjJG5OyxApTdSyNs= +kmodules.xyz/resource-metadata v0.22.3-0.20241117093124-a5b36fb25424 h1:6qDtEIMVVt5xKLXnQIfyU49vxYRattFWPgA65umasc4= +kmodules.xyz/resource-metadata v0.22.3-0.20241117093124-a5b36fb25424/go.mod h1:NqGVv2kpYb6nA4i5jtDVGK5DHUVyw/eE2GtHa+1dWp4= kmodules.xyz/resource-metrics v0.30.5 h1:ZhpGeR9DCz1HTrKUg/mWhr95wlFzCPRdgVAqwaggy1o= kmodules.xyz/resource-metrics v0.30.5/go.mod h1:w9+rz7/s/kGP1GWzYSuRdCn+l7EwpesmESSEHkLBnIQ= kmodules.xyz/resource-metrics/utils v0.30.4 h1:bJS/x0Qr7N1FFdxugFbzZ/Es6HVs4ptsFlhkmgj3jac= diff --git a/pkg/graph/dashboard.go b/pkg/graph/dashboard.go index 796ee01b45..b8e75f484a 100644 --- a/pkg/graph/dashboard.go +++ b/pkg/graph/dashboard.go @@ -37,7 +37,7 @@ import ( "sigs.k8s.io/controller-runtime/pkg/client" ) -func renderDashboard(kc client.Client, oc openvizcs.Interface, srcObj *unstructured.Unstructured) tableconvertor.DashboardRendererFunc { +func renderDashboard(ctx context.Context, kc client.Client, oc openvizcs.Interface, srcObj *unstructured.Unstructured) tableconvertor.DashboardRendererFunc { return func(name string) (*uiapi.ResourceDashboard, string, error) { rd, err := resourcedashboards.LoadByName(kc, name) if err != nil { @@ -52,7 +52,7 @@ func renderDashboard(kc client.Client, oc openvizcs.Interface, srcObj *unstructu if len(rd.Spec.Dashboards) > 1 { return nil, "", fmt.Errorf("multiple dashboards configured for %s", name) } - dg, err := RenderDashboard(kc, oc, rd, srcObj, false) + dg, err := RenderDashboard(ctx, kc, oc, rd, srcObj, false) if err != nil { return nil, "", err } @@ -60,7 +60,7 @@ func renderDashboard(kc client.Client, oc openvizcs.Interface, srcObj *unstructu } } -func RenderDashboard(kc client.Client, oc openvizcs.Interface, rd *uiapi.ResourceDashboard, src *unstructured.Unstructured, embeddedLink bool) (*openvizauipi.DashboardGroup, error) { +func RenderDashboard(ctx context.Context, kc client.Client, oc openvizcs.Interface, rd *uiapi.ResourceDashboard, src *unstructured.Unstructured, embeddedLink bool) (*openvizauipi.DashboardGroup, error) { if rd.Spec.Provider != uiapi.DashboardProviderGrafana { return nil, fmt.Errorf("dashboard %s uses unsupported provider %q", rd.Name, rd.Spec.Provider) } @@ -85,7 +85,7 @@ func RenderDashboard(kc client.Client, oc openvizcs.Interface, rd *uiapi.Resourc result = strings.TrimSpace(result) cond = strings.EqualFold(result, "true") } else if d.If.Connected != nil { - _, targets, err := ExecRawQuery(kc, kmapi.NewObjectID(src).OID(), *d.If.Connected) + _, targets, err := ExecRawQuery(ctx, kc, kmapi.NewObjectID(src).OID(), *d.If.Connected) if err != nil { return nil, errors.Wrapf(err, "failed to check connection for dashboard with title %s", d.Title) } @@ -124,5 +124,5 @@ func RenderDashboard(kc client.Client, oc openvizcs.Interface, rd *uiapi.Resourc } dg.Request.Dashboards = append(dg.Request.Dashboards, out) } - return oc.UiV1alpha1().DashboardGroups().Create(context.TODO(), dg, metav1.CreateOptions{}) + return oc.UiV1alpha1().DashboardGroups().Create(ctx, dg, metav1.CreateOptions{}) } diff --git a/pkg/graph/pods.go b/pkg/graph/pods.go index b7c3dc82f0..fa3ccc088b 100755 --- a/pkg/graph/pods.go +++ b/pkg/graph/pods.go @@ -94,7 +94,7 @@ func LocatePods(ctx context.Context, kc client.Client, req *kmapi.ObjectInfo) ([ }, } - _, refs, err := ExecRawQuery(kc, src.OID(), target) + _, refs, err := ExecRawQuery(ctx, kc, src.OID(), target) if err != nil { return nil, err } diff --git a/pkg/graph/renderer.go b/pkg/graph/renderer.go index 3831f0c229..05a06503f7 100644 --- a/pkg/graph/renderer.go +++ b/pkg/graph/renderer.go @@ -43,6 +43,7 @@ import ( ) func RenderLayout( + ctx context.Context, kc client.Client, oc openvizcs.Interface, src kmapi.ObjectInfo, @@ -57,7 +58,7 @@ func RenderLayout( } var srcObj unstructured.Unstructured srcObj.SetGroupVersionKind(srcRID.GroupVersionKind()) - err = kc.Get(context.TODO(), src.Ref.ObjectKey(), &srcObj) + err = kc.Get(ctx, src.Ref.ObjectKey(), &srcObj) if err != nil { return nil, err } @@ -118,14 +119,14 @@ func RenderLayout( } if layout.Spec.Header != nil && okToRender(layout.Spec.Header.Kind, renderBlocks) { - if bv, err := renderPageBlock(kc, oc, srcRID, &srcObj, layout.Spec.Header, convertToTable); err != nil { + if bv, err := renderPageBlock(ctx, kc, oc, srcRID, &srcObj, layout.Spec.Header, convertToTable); err != nil { return nil, err } else { out.Header = bv } } if layout.Spec.TabBar != nil && okToRender(layout.Spec.TabBar.Kind, renderBlocks) { - if bv, err := renderPageBlock(kc, oc, srcRID, &srcObj, layout.Spec.TabBar, convertToTable); err != nil { + if bv, err := renderPageBlock(ctx, kc, oc, srcRID, &srcObj, layout.Spec.TabBar, convertToTable); err != nil { return nil, err } else { out.TabBar = bv @@ -151,14 +152,14 @@ func RenderLayout( Blocks: nil, } if sectionLayout.Info != nil && okToRender(sectionLayout.Info.Kind, renderBlocks) { - if bv, err := renderPageBlock(kc, oc, srcRID, &srcObj, sectionLayout.Info, convertToTable); err != nil { + if bv, err := renderPageBlock(ctx, kc, oc, srcRID, &srcObj, sectionLayout.Info, convertToTable); err != nil { return nil, err } else { section.Info = bv } } if sectionLayout.Insight != nil && okToRender(sectionLayout.Insight.Kind, renderBlocks) { - if bv, err := renderPageBlock(kc, oc, srcRID, &srcObj, sectionLayout.Insight, convertToTable); err != nil { + if bv, err := renderPageBlock(ctx, kc, oc, srcRID, &srcObj, sectionLayout.Insight, convertToTable); err != nil { return nil, err } else { section.Insight = bv @@ -168,7 +169,7 @@ func RenderLayout( blocks := make([]rsapi.PageBlockView, 0, len(sectionLayout.Blocks)) for _, block := range sectionLayout.Blocks { if okToRender(block.Kind, renderBlocks) { - if bv, err := renderPageBlock(kc, oc, srcRID, &srcObj, &block, convertToTable); err != nil { + if bv, err := renderPageBlock(ctx, kc, oc, srcRID, &srcObj, &block, convertToTable); err != nil { return nil, err } else { blocks = append(blocks, *bv) @@ -190,23 +191,23 @@ func okToRender(kind rsapi.TableKind, renderBlocks sets.Set[string]) bool { return renderBlocks.Len() == 0 || renderBlocks.Has(string(kind)) } -func RenderPageBlock(kc client.Client, oc openvizcs.Interface, src kmapi.ObjectInfo, block *rsapi.PageBlockLayout, convertToTable bool) (*rsapi.PageBlockView, error) { +func RenderPageBlock(ctx context.Context, kc client.Client, oc openvizcs.Interface, src kmapi.ObjectInfo, block *rsapi.PageBlockLayout, convertToTable bool) (*rsapi.PageBlockView, error) { srcRID, err := kmapi.ExtractResourceID(kc.RESTMapper(), src.Resource) if err != nil { return nil, errors.Wrap(err, "failed to detect src resource id") } var srcObj unstructured.Unstructured srcObj.SetGroupVersionKind(srcRID.GroupVersionKind()) - err = kc.Get(context.TODO(), src.Ref.ObjectKey(), &srcObj) + err = kc.Get(ctx, src.Ref.ObjectKey(), &srcObj) if err != nil { return nil, err } - return renderPageBlock(kc, oc, srcRID, &srcObj, block, convertToTable) + return renderPageBlock(ctx, kc, oc, srcRID, &srcObj, block, convertToTable) } -func renderPageBlock(kc client.Client, oc openvizcs.Interface, srcRID *kmapi.ResourceID, srcObj *unstructured.Unstructured, block *rsapi.PageBlockLayout, convertToTable bool) (*rsapi.PageBlockView, error) { - bv, err := _renderPageBlock(kc, oc, srcRID, srcObj, block, convertToTable) +func renderPageBlock(ctx context.Context, kc client.Client, oc openvizcs.Interface, srcRID *kmapi.ResourceID, srcObj *unstructured.Unstructured, block *rsapi.PageBlockLayout, convertToTable bool) (*rsapi.PageBlockView, error) { + bv, err := _renderPageBlock(ctx, kc, oc, srcRID, srcObj, block, convertToTable) if err != nil { bv.Result = rsapi.RenderResult{ Status: rsapi.RenderError, @@ -220,7 +221,12 @@ func renderPageBlock(kc client.Client, oc openvizcs.Interface, srcRID *kmapi.Res return bv, nil } -func _renderPageBlock(kc client.Client, oc openvizcs.Interface, srcRID *kmapi.ResourceID, srcObj *unstructured.Unstructured, block *rsapi.PageBlockLayout, convertToTable bool) (*rsapi.PageBlockView, error) { +func _renderPageBlock(ctx context.Context, kc client.Client, oc openvizcs.Interface, srcRID *kmapi.ResourceID, srcObj *unstructured.Unstructured, block *rsapi.PageBlockLayout, convertToTable bool) (*rsapi.PageBlockView, error) { + cc, err := getClient(ctx, kc, block.Impersonate) + if err != nil { + return nil, err + } + out := rsapi.PageBlockView{ Kind: block.Kind, Name: block.Name, @@ -231,11 +237,11 @@ func _renderPageBlock(kc client.Client, oc openvizcs.Interface, srcRID *kmapi.Re if block.Kind == rsapi.TableKindSelf || block.Kind == rsapi.TableKindSubTable { out.Resource = srcRID if convertToTable { - converter, err := tableconvertor.New(block.FieldPath, block.View.Columns, renderDashboard(kc, oc, srcObj), RenderExec(nil, &srcGVR)) + converter, err := tableconvertor.New(block.FieldPath, block.View.Columns, renderDashboard(ctx, cc, oc, srcObj), RenderExec(nil, &srcGVR)) if err != nil { return &out, err } - table, err := converter.ConvertToTable(context.TODO(), srcObj) + table, err := converter.ConvertToTable(ctx, srcObj) if err != nil { return &out, err } @@ -248,7 +254,7 @@ func _renderPageBlock(kc client.Client, oc openvizcs.Interface, srcRID *kmapi.Re return &out, fmt.Errorf("unsupported table kind found in block %+v", block) } - mapping, err := kc.RESTMapper().RESTMapping(schema.GroupKind{ + mapping, err := cc.RESTMapper().RESTMapping(schema.GroupKind{ Group: block.Ref.Group, Kind: block.Ref.Kind, }) @@ -292,24 +298,24 @@ func _renderPageBlock(kc client.Client, oc openvizcs.Interface, srcRID *kmapi.Re // handle FalcoEvent list call if vars[sharedapi.GraphQueryVarTargetGroup] == falco.GroupName && vars[sharedapi.GraphQueryVarTargetKind] == falcov1alpha1.ResourceKindFalcoEvent { - objs, err = listFalcoEvents(kc, block, srcID) + objs, err = listFalcoEvents(ctx, cc, block, srcID) if err != nil { return &out, err } } else { - objs, err = ExecGraphQLQuery(kc, q, vars) + objs, err = ExecGraphQLQuery(cc, q, vars) if err != nil { return &out, err } } if convertToTable { - converter, err := tableconvertor.New(block.FieldPath, block.View.Columns, renderDashboard(kc, oc, srcObj), RenderExec(&srcGVR, &mapping.Resource)) + converter, err := tableconvertor.New(block.FieldPath, block.View.Columns, renderDashboard(ctx, cc, oc, srcObj), RenderExec(&srcGVR, &mapping.Resource)) if err != nil { return &out, err } list := &unstructured.UnstructuredList{Items: objs} - table, err := converter.ConvertToTable(context.TODO(), list) + table, err := converter.ConvertToTable(ctx, list) if err != nil { return &out, err } @@ -327,17 +333,17 @@ func _renderPageBlock(kc client.Client, oc openvizcs.Interface, srcRID *kmapi.Re } u := unstructured.Unstructured{Object: obj} u.SetGroupVersionKind(mapping.GroupVersionKind) - err = kc.Create(context.TODO(), &u) + err = cc.Create(ctx, &u) if err != nil { return &out, err } if convertToTable { - converter, err := tableconvertor.New(block.FieldPath, block.View.Columns, renderDashboard(kc, oc, srcObj), RenderExec(&srcGVR, &mapping.Resource)) + converter, err := tableconvertor.New(block.FieldPath, block.View.Columns, renderDashboard(ctx, cc, oc, srcObj), RenderExec(&srcGVR, &mapping.Resource)) if err != nil { return &out, err } - table, err := converter.ConvertToTable(context.TODO(), &u) + table, err := converter.ConvertToTable(ctx, &u) if err != nil { return &out, err } @@ -349,7 +355,7 @@ func _renderPageBlock(kc client.Client, oc openvizcs.Interface, srcRID *kmapi.Re return &out, nil } -func listFalcoEvents(kc client.Client, block *rsapi.PageBlockLayout, srcID *kmapi.ObjectID) ([]unstructured.Unstructured, error) { +func listFalcoEvents(ctx context.Context, kc client.Client, block *rsapi.PageBlockLayout, srcID *kmapi.ObjectID) ([]unstructured.Unstructured, error) { var refs []kmapi.ObjectReference var err error if srcID.Kind == "Pod" { @@ -376,7 +382,7 @@ func listFalcoEvents(kc client.Client, block *rsapi.PageBlockLayout, srcID *kmap var list unstructured.UnstructuredList list.SetGroupVersionKind(falcov1alpha1.SchemeGroupVersion.WithKind(falcov1alpha1.ResourceKindFalcoEvent)) - err = kc.List(context.TODO(), &list, &client.ListOptions{LabelSelector: selector}) + err = kc.List(ctx, &list, &client.ListOptions{LabelSelector: selector}) if meta.IsNoMatchError(err) { return nil, err } else if err == nil { diff --git a/pkg/graph/setup.go b/pkg/graph/setup.go index b0868f23a0..385d7c947e 100644 --- a/pkg/graph/setup.go +++ b/pkg/graph/setup.go @@ -34,12 +34,14 @@ import ( "k8s.io/apimachinery/pkg/runtime/schema" utilerrors "k8s.io/apimachinery/pkg/util/errors" "k8s.io/apimachinery/pkg/util/wait" + "k8s.io/apiserver/pkg/endpoints/request" "k8s.io/client-go/discovery" "k8s.io/client-go/kubernetes" _ "k8s.io/client-go/plugin/pkg/client/auth" restclient "k8s.io/client-go/rest" "k8s.io/klog/v2" kmapi "kmodules.xyz/client-go/api/v1" + cu "kmodules.xyz/client-go/client" meta_util "kmodules.xyz/client-go/meta" sharedapi "kmodules.xyz/resource-metadata/apis/shared" ksets "kmodules.xyz/sets" @@ -247,8 +249,13 @@ func extractRefs(data map[string]interface{}, result ksets.ObjectReference) erro return nil } -func ExecRawQuery(kc client.Client, src kmapi.OID, target sharedapi.ResourceLocator) (*kmapi.ResourceID, []kmapi.ObjectReference, error) { - mapping, err := kc.RESTMapper().RESTMapping(schema.GroupKind{ +func ExecRawQuery(ctx context.Context, kc client.Client, src kmapi.OID, target sharedapi.ResourceLocator) (*kmapi.ResourceID, []kmapi.ObjectReference, error) { + cc, err := getClient(ctx, kc, target.Impersonate) + if err != nil { + return nil, nil, err + } + + mapping, err := cc.RESTMapper().RESTMapping(schema.GroupKind{ Group: target.Ref.Group, Kind: target.Ref.Kind, }) @@ -267,7 +274,7 @@ func ExecRawQuery(kc client.Client, src kmapi.OID, target sharedapi.ResourceLoca return rid, result, err } - obj, err := execRestQuery(kc, q, mapping.GroupVersionKind) + obj, err := execRestQuery(ctx, cc, q, mapping.GroupVersionKind) if err != nil { return nil, nil, err } @@ -278,8 +285,13 @@ func ExecRawQuery(kc client.Client, src kmapi.OID, target sharedapi.ResourceLoca return rid, []kmapi.ObjectReference{ref}, nil } -func ExecQuery(kc client.Client, src kmapi.OID, target sharedapi.ResourceLocator) (*kmapi.ResourceID, []unstructured.Unstructured, error) { - mapping, err := kc.RESTMapper().RESTMapping(schema.GroupKind{ +func ExecQuery(ctx context.Context, kc client.Client, src kmapi.OID, target sharedapi.ResourceLocator) (*kmapi.ResourceID, []unstructured.Unstructured, error) { + cc, err := getClient(ctx, kc, target.Impersonate) + if err != nil { + return nil, nil, err + } + + mapping, err := cc.RESTMapper().RESTMapping(schema.GroupKind{ Group: target.Ref.Group, Kind: target.Ref.Kind, }) @@ -294,18 +306,18 @@ func ExecQuery(kc client.Client, src kmapi.OID, target sharedapi.ResourceLocator } if target.Query.Type == sharedapi.GraphQLQuery { - result, err := ExecGraphQLQuery(kc, q, vars) + result, err := ExecGraphQLQuery(cc, q, vars) return rid, result, err } - obj, err := execRestQuery(kc, q, mapping.GroupVersionKind) + obj, err := execRestQuery(ctx, cc, q, mapping.GroupVersionKind) if err != nil { return rid, nil, err } return rid, []unstructured.Unstructured{*obj}, nil } -func execRestQuery(kc client.Client, q string, gvk schema.GroupVersionKind) (*unstructured.Unstructured, error) { +func execRestQuery(ctx context.Context, kc client.Client, q string, gvk schema.GroupVersionKind) (*unstructured.Unstructured, error) { var out unstructured.Unstructured err := yaml.Unmarshal([]byte(q), &out) if err != nil { @@ -313,9 +325,22 @@ func execRestQuery(kc client.Client, q string, gvk schema.GroupVersionKind) (*un } out.SetGroupVersionKind(gvk) - err = kc.Create(context.TODO(), &out) + err = kc.Create(ctx, &out) if err != nil { return nil, err } return &out, nil } + +func getClient(ctx context.Context, kc client.Client, impersonate bool) (client.Client, error) { + u, found := request.UserFrom(ctx) + + if !impersonate || !found { + return kc, nil + } + + if rw, ok := kc.(*cu.DelegatingClient); ok { + return rw.Impersonate(u) + } + return nil, fmt.Errorf("can't impersonate client") +} diff --git a/pkg/registry/core/resourceservice/storage.go b/pkg/registry/core/resourceservice/storage.go index 2128e16ed1..7d9feb8be5 100644 --- a/pkg/registry/core/resourceservice/storage.go +++ b/pkg/registry/core/resourceservice/storage.go @@ -159,7 +159,7 @@ func (r *Storage) Get(ctx context.Context, name string, options *metav1.GetOptio return nil, err } - return r.toGenericResourceService(obj, rid, cmeta) + return r.toGenericResourceService(ctx, obj, rid, cmeta) } func (r *Storage) List(ctx context.Context, options *internalversion.ListOptions) (runtime.Object, error) { @@ -236,7 +236,7 @@ func (r *Storage) List(ctx context.Context, options *internalversion.ListOptions continue } - genres, err := r.toGenericResourceService(item, apiType, cmeta) + genres, err := r.toGenericResourceService(ctx, item, apiType, cmeta) if err != nil { return nil, err } @@ -275,7 +275,7 @@ func (r *Storage) ConvertToTable(ctx context.Context, object runtime.Object, tab return r.convertor.ConvertToTable(ctx, object, tableOptions) } -func (r *Storage) toGenericResourceService(item unstructured.Unstructured, apiType *kmapi.ResourceID, cmeta *kmapi.ClusterMetadata) (*rscoreapi.GenericResourceService, error) { +func (r *Storage) toGenericResourceService(ctx context.Context, item unstructured.Unstructured, apiType *kmapi.ResourceID, cmeta *kmapi.ClusterMetadata) (*rscoreapi.GenericResourceService, error) { content := item.UnstructuredContent() objID := kmapi.NewObjectID(&item) @@ -347,7 +347,7 @@ func (r *Storage) toGenericResourceService(item unstructured.Unstructured, apiTy } { - rid, objs, err := graph.ExecQuery(r.kc, oid, sharedapi.ResourceLocator{ + rid, objs, err := graph.ExecQuery(ctx, r.kc, oid, sharedapi.ResourceLocator{ Ref: metav1.GroupKind{ Group: "", Kind: "Service", @@ -388,7 +388,7 @@ func (r *Storage) toGenericResourceService(item unstructured.Unstructured, apiTy } } if apiType.Group == "kubedb.com" { - rid, objs, err := graph.ExecQuery(r.kc, oid, sharedapi.ResourceLocator{ + rid, objs, err := graph.ExecQuery(ctx, r.kc, oid, sharedapi.ResourceLocator{ Ref: metav1.GroupKind{ Group: "catalog.appscode.com", Kind: apiType.Kind + "Binding", @@ -448,7 +448,7 @@ func (r *Storage) toGenericResourceService(item unstructured.Unstructured, apiTy } } { - rid, refs, err := graph.ExecRawQuery(r.kc, oid, sharedapi.ResourceLocator{ + rid, refs, err := graph.ExecRawQuery(ctx, r.kc, oid, sharedapi.ResourceLocator{ Ref: metav1.GroupKind{ Group: "stash.appscode.com", Kind: "BackupSession", @@ -476,7 +476,7 @@ func (r *Storage) toGenericResourceService(item unstructured.Unstructured, apiTy } } if genres.Spec.Facilities.Backup.Usage == rscoreapi.FacilityUnknown { - rid, refs, err := graph.ExecRawQuery(r.kc, oid, sharedapi.ResourceLocator{ + rid, refs, err := graph.ExecRawQuery(ctx, r.kc, oid, sharedapi.ResourceLocator{ Ref: metav1.GroupKind{ Group: "core.kubestash.com", Kind: "BackupConfiguration", @@ -497,7 +497,7 @@ func (r *Storage) toGenericResourceService(item unstructured.Unstructured, apiTy } } { - rid, refs, err := graph.ExecRawQuery(r.kc, oid, sharedapi.ResourceLocator{ + rid, refs, err := graph.ExecRawQuery(ctx, r.kc, oid, sharedapi.ResourceLocator{ Ref: metav1.GroupKind{ Group: "monitoring.coreos.com", Kind: "ServiceMonitor", @@ -525,7 +525,7 @@ func (r *Storage) toGenericResourceService(item unstructured.Unstructured, apiTy } if genres.Spec.Facilities.Monitoring.Usage == rscoreapi.FacilityUnknown { - rid, refs, err = graph.ExecRawQuery(r.kc, oid, sharedapi.ResourceLocator{ + rid, refs, err = graph.ExecRawQuery(ctx, r.kc, oid, sharedapi.ResourceLocator{ Ref: metav1.GroupKind{ Group: "monitoring.coreos.com", Kind: "PodMonitor", @@ -575,7 +575,7 @@ func (r *Storage) toGenericResourceService(item unstructured.Unstructured, apiTy result = strings.TrimSpace(result) cond = strings.EqualFold(result, "true") } else if exec.If.Connected != nil { - _, targets, err := graph.ExecRawQuery(r.kc, oid, *exec.If.Connected) + _, targets, err := graph.ExecRawQuery(ctx, r.kc, oid, *exec.If.Connected) if err != nil { return nil, errors.Wrapf(err, "failed to check connection for %+v exec with alias %s", gvr, exec.Alias) } diff --git a/pkg/registry/meta/render/storage.go b/pkg/registry/meta/render/storage.go index 29b315c302..fb83c41fc9 100644 --- a/pkg/registry/meta/render/storage.go +++ b/pkg/registry/meta/render/storage.go @@ -107,7 +107,7 @@ func (r *Storage) Create(ctx context.Context, obj runtime.Object, _ rest.Validat autoColumns = true } - bv, err := graph.RenderPageBlock(r.kc, r.oc, req.Source, req.Block, req.ConvertToTable) + bv, err := graph.RenderPageBlock(ctx, r.kc, r.oc, req.Source, req.Block, req.ConvertToTable) if err != nil { return nil, err } @@ -121,6 +121,7 @@ func (r *Storage) Create(ctx context.Context, obj runtime.Object, _ rest.Validat renderBlocks.Insert(string(k)) } rv, err := graph.RenderLayout( + ctx, r.kc, r.oc, req.Source, diff --git a/pkg/registry/meta/renderdashboard/storage.go b/pkg/registry/meta/renderdashboard/storage.go index 893c42002a..0393765d2c 100644 --- a/pkg/registry/meta/renderdashboard/storage.go +++ b/pkg/registry/meta/renderdashboard/storage.go @@ -132,7 +132,7 @@ func (r *Storage) Create(ctx context.Context, obj runtime.Object, _ rest.Validat } } - dg, err := graph.RenderDashboard(r.kc, r.oc, rd, src, req.EmbeddedLink) + dg, err := graph.RenderDashboard(ctx, r.kc, r.oc, rd, src, req.EmbeddedLink) if err != nil { return nil, err } diff --git a/pkg/registry/meta/resourcequery/storage.go b/pkg/registry/meta/resourcequery/storage.go index afdd5f9ccf..b03df2cd31 100644 --- a/pkg/registry/meta/resourcequery/storage.go +++ b/pkg/registry/meta/resourcequery/storage.go @@ -106,7 +106,7 @@ func (r *Storage) Create(ctx context.Context, obj runtime.Object, _ rest.Validat src := kmapi.NewObjectID(&out) if req.OutputFormat == rsapi.OutputFormatRef { - _, refs, err := graph.ExecRawQuery(r.kc, src.OID(), *req.Target) + _, refs, err := graph.ExecRawQuery(ctx, r.kc, src.OID(), *req.Target) if err != nil { return nil, err } @@ -116,7 +116,7 @@ func (r *Storage) Create(ctx context.Context, obj runtime.Object, _ rest.Validat } in.Response = &runtime.RawExtension{Raw: data} } else { - rid2, items, err := graph.ExecQuery(r.kc, src.OID(), *req.Target) + rid2, items, err := graph.ExecQuery(ctx, r.kc, src.OID(), *req.Target) if err != nil { return nil, err } diff --git a/vendor/kmodules.xyz/client-go/api/v1/cluster.go b/vendor/kmodules.xyz/client-go/api/v1/cluster.go index 079bceb34d..b40cd8d1ef 100644 --- a/vendor/kmodules.xyz/client-go/api/v1/cluster.go +++ b/vendor/kmodules.xyz/client-go/api/v1/cluster.go @@ -35,12 +35,21 @@ const ( HostingProviderGeneric HostingProvider = "Generic" HostingProviderGKE HostingProvider = "GKE" HostingProviderLinode HostingProvider = "Linode" + HostingProviderAkamai HostingProvider = "Akamai" HostingProviderPacket HostingProvider = "Packet" HostingProviderRancher HostingProvider = "Rancher" HostingProviderScaleway HostingProvider = "Scaleway" HostingProviderVultr HostingProvider = "Vultr" ) +func (h HostingProvider) ConvertToPreferredProvider() HostingProvider { + switch h { + case HostingProviderLinode: + return HostingProviderAkamai + } + return h +} + const ( AceInfoConfigMapName = "ace-info" diff --git a/vendor/kmodules.xyz/client-go/client/delegated.go b/vendor/kmodules.xyz/client-go/client/delegated.go index fd36791a68..445ecf09da 100644 --- a/vendor/kmodules.xyz/client-go/client/delegated.go +++ b/vendor/kmodules.xyz/client-go/client/delegated.go @@ -26,6 +26,7 @@ import ( "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apiserver/pkg/authentication/user" restclient "k8s.io/client-go/rest" "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/controller-runtime/pkg/client/apiutil" @@ -36,6 +37,9 @@ import ( // NewDelegatingClientInput encapsulates the input parameters to create a new delegating client. type NewDelegatingClientInput struct { + config *restclient.Config + options client.Options + CacheReader client.Reader Client client.Client UncachedObjects []client.Object @@ -58,9 +62,11 @@ func NewDelegatingClient(in NewDelegatingClientInput) (client.Client, error) { uncachedGVKs[gvk] = struct{}{} } - return &delegatingClient{ - scheme: in.Client.Scheme(), - mapper: in.Client.RESTMapper(), + return &DelegatingClient{ + config: in.config, + options: in.options, + scheme: in.Client.Scheme(), + mapper: in.Client.RESTMapper(), Reader: &delegatingReader{ CacheReader: in.CacheReader, ClientReader: in.Client, @@ -75,7 +81,7 @@ func NewDelegatingClient(in NewDelegatingClientInput) (client.Client, error) { }, nil } -type delegatingClient struct { +type DelegatingClient struct { client.Reader client.Writer client.StatusClient @@ -83,25 +89,43 @@ type delegatingClient struct { scheme *runtime.Scheme mapper meta.RESTMapper + + config *restclient.Config + options client.Options +} + +func (d *DelegatingClient) RestConfig() *restclient.Config { + return d.config +} + +func (d *DelegatingClient) Impersonate(u user.Info) (client.Client, error) { + config := restclient.CopyConfig(d.config) + config.Impersonate = restclient.ImpersonationConfig{ + UserName: u.GetName(), + UID: u.GetUID(), + Groups: u.GetGroups(), + Extra: u.GetExtra(), + } + return NewClient(config, d.options) } // GroupVersionKindFor returns the GroupVersionKind for the given object. -func (d *delegatingClient) GroupVersionKindFor(obj runtime.Object) (schema.GroupVersionKind, error) { +func (d *DelegatingClient) GroupVersionKindFor(obj runtime.Object) (schema.GroupVersionKind, error) { return apiutil.GVKForObject(obj, d.scheme) } // IsObjectNamespaced returns true if the GroupVersionKind of the object is namespaced. -func (d *delegatingClient) IsObjectNamespaced(obj runtime.Object) (bool, error) { +func (d *DelegatingClient) IsObjectNamespaced(obj runtime.Object) (bool, error) { return apiutil.IsObjectNamespaced(obj, d.scheme, d.mapper) } // Scheme returns the scheme this client is using. -func (d *delegatingClient) Scheme() *runtime.Scheme { +func (d *DelegatingClient) Scheme() *runtime.Scheme { return d.scheme } // RESTMapper returns the rest mapper this client is using. -func (d *delegatingClient) RESTMapper() meta.RESTMapper { +func (d *DelegatingClient) RESTMapper() meta.RESTMapper { return d.mapper } @@ -167,7 +191,7 @@ func (d *delegatingReader) List(ctx context.Context, list client.ObjectList, opt return d.CacheReader.List(ctx, list, opts...) } -func (d *delegatingClient) SubResource(subResource string) client.SubResourceClient { +func (d *DelegatingClient) SubResource(subResource string) client.SubResourceClient { return d.SubResourceClientConstructor.SubResource(subResource) } @@ -181,6 +205,8 @@ func NewClient(config *restclient.Config, options client.Options) (client.Client return nil, err } co := NewDelegatingClientInput{ + config: config, + options: options, Client: c, Cachable: cachable, } diff --git a/vendor/kmodules.xyz/resource-metadata/apis/core/v1alpha1/openapi_generated.go b/vendor/kmodules.xyz/resource-metadata/apis/core/v1alpha1/openapi_generated.go index 1c55fc1c24..c50c8da964 100644 --- a/vendor/kmodules.xyz/resource-metadata/apis/core/v1alpha1/openapi_generated.go +++ b/vendor/kmodules.xyz/resource-metadata/apis/core/v1alpha1/openapi_generated.go @@ -20324,6 +20324,12 @@ func schema_resource_metadata_apis_core_v1alpha1_Service(ref common.ReferenceCal Ref: ref("kmodules.xyz/resource-metadata/apis/shared.ResourceQuery"), }, }, + "impersonate": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, }, Required: []string{"name", "ref", "query"}, }, @@ -21056,6 +21062,12 @@ func schema_kmodulesxyz_resource_metadata_apis_shared_ResourceLocator(ref common Ref: ref("kmodules.xyz/resource-metadata/apis/shared.ResourceQuery"), }, }, + "impersonate": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, }, Required: []string{"ref", "query"}, }, diff --git a/vendor/kmodules.xyz/resource-metadata/apis/identity/v1alpha1/openapi_generated.go b/vendor/kmodules.xyz/resource-metadata/apis/identity/v1alpha1/openapi_generated.go index f94454fb27..20795b9899 100644 --- a/vendor/kmodules.xyz/resource-metadata/apis/identity/v1alpha1/openapi_generated.go +++ b/vendor/kmodules.xyz/resource-metadata/apis/identity/v1alpha1/openapi_generated.go @@ -20358,6 +20358,12 @@ func schema_kmodulesxyz_resource_metadata_apis_shared_ResourceLocator(ref common Ref: ref("kmodules.xyz/resource-metadata/apis/shared.ResourceQuery"), }, }, + "impersonate": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, }, Required: []string{"ref", "query"}, }, diff --git a/vendor/kmodules.xyz/resource-metadata/apis/management/v1alpha1/openapi_generated.go b/vendor/kmodules.xyz/resource-metadata/apis/management/v1alpha1/openapi_generated.go index 328afc2a6d..8829d0ac9f 100644 --- a/vendor/kmodules.xyz/resource-metadata/apis/management/v1alpha1/openapi_generated.go +++ b/vendor/kmodules.xyz/resource-metadata/apis/management/v1alpha1/openapi_generated.go @@ -19804,6 +19804,12 @@ func schema_kmodulesxyz_resource_metadata_apis_shared_ResourceLocator(ref common Ref: ref("kmodules.xyz/resource-metadata/apis/shared.ResourceQuery"), }, }, + "impersonate": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, }, Required: []string{"ref", "query"}, }, diff --git a/vendor/kmodules.xyz/resource-metadata/apis/meta/v1alpha1/openapi_generated.go b/vendor/kmodules.xyz/resource-metadata/apis/meta/v1alpha1/openapi_generated.go index e46825cd7c..ee4ca5c158 100644 --- a/vendor/kmodules.xyz/resource-metadata/apis/meta/v1alpha1/openapi_generated.go +++ b/vendor/kmodules.xyz/resource-metadata/apis/meta/v1alpha1/openapi_generated.go @@ -20434,6 +20434,12 @@ func schema_resource_metadata_apis_meta_v1alpha1_PageBlockLayout(ref common.Refe Ref: ref("kmodules.xyz/resource-metadata/apis/shared.ResourceQuery"), }, }, + "impersonate": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, "displayMode": { SchemaProps: spec.SchemaProps{ Type: []string{"string"}, @@ -20538,6 +20544,12 @@ func schema_resource_metadata_apis_meta_v1alpha1_PageBlockOutline(ref common.Ref Ref: ref("kmodules.xyz/resource-metadata/apis/shared.ResourceQuery"), }, }, + "impersonate": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, "displayMode": { SchemaProps: spec.SchemaProps{ Type: []string{"string"}, @@ -24181,6 +24193,12 @@ func schema_kmodulesxyz_resource_metadata_apis_shared_ResourceLocator(ref common Ref: ref("kmodules.xyz/resource-metadata/apis/shared.ResourceQuery"), }, }, + "impersonate": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, }, Required: []string{"ref", "query"}, }, diff --git a/vendor/kmodules.xyz/resource-metadata/apis/shared/openapi_generated.go b/vendor/kmodules.xyz/resource-metadata/apis/shared/openapi_generated.go index c378451217..7ca8bc9b6f 100644 --- a/vendor/kmodules.xyz/resource-metadata/apis/shared/openapi_generated.go +++ b/vendor/kmodules.xyz/resource-metadata/apis/shared/openapi_generated.go @@ -777,6 +777,12 @@ func schema_kmodulesxyz_resource_metadata_apis_shared_ResourceLocator(ref common Ref: ref("kmodules.xyz/resource-metadata/apis/shared.ResourceQuery"), }, }, + "impersonate": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, }, Required: []string{"ref", "query"}, }, diff --git a/vendor/kmodules.xyz/resource-metadata/apis/shared/types.go b/vendor/kmodules.xyz/resource-metadata/apis/shared/types.go index 930c6bf4bb..2d91b13702 100644 --- a/vendor/kmodules.xyz/resource-metadata/apis/shared/types.go +++ b/vendor/kmodules.xyz/resource-metadata/apis/shared/types.go @@ -38,8 +38,9 @@ type DeploymentParameters struct { } type ResourceLocator struct { - Ref metav1.GroupKind `json:"ref"` - Query ResourceQuery `json:"query"` + Ref metav1.GroupKind `json:"ref"` + Query ResourceQuery `json:"query"` + Impersonate bool `json:"impersonate,omitempty"` } // +kubebuilder:validation:Enum=REST;GraphQL diff --git a/vendor/kmodules.xyz/resource-metadata/apis/ui/v1alpha1/openapi_generated.go b/vendor/kmodules.xyz/resource-metadata/apis/ui/v1alpha1/openapi_generated.go index aa03fb4b39..babdac0523 100644 --- a/vendor/kmodules.xyz/resource-metadata/apis/ui/v1alpha1/openapi_generated.go +++ b/vendor/kmodules.xyz/resource-metadata/apis/ui/v1alpha1/openapi_generated.go @@ -19571,6 +19571,12 @@ func schema_kmodulesxyz_resource_metadata_apis_shared_ResourceLocator(ref common Ref: ref("kmodules.xyz/resource-metadata/apis/shared.ResourceQuery"), }, }, + "impersonate": { + SchemaProps: spec.SchemaProps{ + Type: []string{"boolean"}, + Format: "", + }, + }, }, Required: []string{"ref", "query"}, }, diff --git a/vendor/kmodules.xyz/resource-metadata/crds/meta.k8s.appscode.com_resourceblockdefinitions.yaml b/vendor/kmodules.xyz/resource-metadata/crds/meta.k8s.appscode.com_resourceblockdefinitions.yaml index b40561554b..8e6c168658 100644 --- a/vendor/kmodules.xyz/resource-metadata/crds/meta.k8s.appscode.com_resourceblockdefinitions.yaml +++ b/vendor/kmodules.xyz/resource-metadata/crds/meta.k8s.appscode.com_resourceblockdefinitions.yaml @@ -71,6 +71,8 @@ spec: - src type: object type: array + impersonate: + type: boolean kind: enum: - Block diff --git a/vendor/kmodules.xyz/resource-metadata/crds/meta.k8s.appscode.com_resourcedescriptors.yaml b/vendor/kmodules.xyz/resource-metadata/crds/meta.k8s.appscode.com_resourcedescriptors.yaml index 11baf8a09b..39a4164890 100644 --- a/vendor/kmodules.xyz/resource-metadata/crds/meta.k8s.appscode.com_resourcedescriptors.yaml +++ b/vendor/kmodules.xyz/resource-metadata/crds/meta.k8s.appscode.com_resourcedescriptors.yaml @@ -204,6 +204,8 @@ spec: type: string connected: properties: + impersonate: + type: boolean query: properties: byLabel: diff --git a/vendor/kmodules.xyz/resource-metadata/crds/meta.k8s.appscode.com_resourcelayouts.yaml b/vendor/kmodules.xyz/resource-metadata/crds/meta.k8s.appscode.com_resourcelayouts.yaml index 787c7840eb..a33b5fd102 100644 --- a/vendor/kmodules.xyz/resource-metadata/crds/meta.k8s.appscode.com_resourcelayouts.yaml +++ b/vendor/kmodules.xyz/resource-metadata/crds/meta.k8s.appscode.com_resourcelayouts.yaml @@ -72,6 +72,8 @@ spec: - src type: object type: array + impersonate: + type: boolean kind: enum: - Block @@ -321,6 +323,8 @@ spec: - src type: object type: array + impersonate: + type: boolean kind: enum: - Block @@ -590,6 +594,8 @@ spec: - src type: object type: array + impersonate: + type: boolean kind: enum: - Block @@ -832,6 +838,8 @@ spec: - src type: object type: array + impersonate: + type: boolean kind: enum: - Block @@ -1110,6 +1118,8 @@ spec: - src type: object type: array + impersonate: + type: boolean kind: enum: - Block diff --git a/vendor/kmodules.xyz/resource-metadata/crds/meta.k8s.appscode.com_resourceoutlines.yaml b/vendor/kmodules.xyz/resource-metadata/crds/meta.k8s.appscode.com_resourceoutlines.yaml index 1ea281924f..3861c1ba60 100644 --- a/vendor/kmodules.xyz/resource-metadata/crds/meta.k8s.appscode.com_resourceoutlines.yaml +++ b/vendor/kmodules.xyz/resource-metadata/crds/meta.k8s.appscode.com_resourceoutlines.yaml @@ -159,6 +159,8 @@ spec: - src type: object type: array + impersonate: + type: boolean kind: enum: - Block @@ -410,6 +412,8 @@ spec: - src type: object type: array + impersonate: + type: boolean kind: enum: - Block @@ -681,6 +685,8 @@ spec: - src type: object type: array + impersonate: + type: boolean kind: enum: - Block @@ -925,6 +931,8 @@ spec: - src type: object type: array + impersonate: + type: boolean kind: enum: - Block @@ -1205,6 +1213,8 @@ spec: - src type: object type: array + impersonate: + type: boolean kind: enum: - Block diff --git a/vendor/kmodules.xyz/resource-metadata/crds/ui.k8s.appscode.com_resourcedashboards.yaml b/vendor/kmodules.xyz/resource-metadata/crds/ui.k8s.appscode.com_resourcedashboards.yaml index 58bdddecac..15bb0dbec8 100644 --- a/vendor/kmodules.xyz/resource-metadata/crds/ui.k8s.appscode.com_resourcedashboards.yaml +++ b/vendor/kmodules.xyz/resource-metadata/crds/ui.k8s.appscode.com_resourcedashboards.yaml @@ -48,6 +48,8 @@ spec: type: string connected: properties: + impersonate: + type: boolean query: properties: byLabel: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/clusterprofiles/ace/dbaas-generic.yaml b/vendor/kmodules.xyz/resource-metadata/hub/clusterprofiles/ace/dbaas-generic.yaml index d0a9858770..473a5a0239 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/clusterprofiles/ace/dbaas-generic.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/clusterprofiles/ace/dbaas-generic.yaml @@ -23,6 +23,7 @@ spec: - kube-prometheus-stack - monitoring-operator - panopticon + - prometheus-adapter opscenter-security: - cert-manager - cert-manager-csi-driver-cacerts diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/elasticsearches.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/elasticsearches.yaml index d90c6de2b6..6cd26ec53f 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/elasticsearches.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/elasticsearches.yaml @@ -31,6 +31,7 @@ spec: create: Never displayMode: List fieldPath: '{.response.dashboards[0].panels}' + impersonate: true kind: Connection name: Dashboards query: @@ -134,6 +135,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/kafkas.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/kafkas.yaml index 01e2eaf730..9634e76d17 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/kafkas.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/kafkas.yaml @@ -80,6 +80,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/mariadbs.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/mariadbs.yaml index 938f9ad423..b00d573a97 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/mariadbs.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/mariadbs.yaml @@ -31,6 +31,7 @@ spec: create: Never displayMode: List fieldPath: '{.response.dashboards[0].panels}' + impersonate: true kind: Connection name: Dashboards query: @@ -134,6 +135,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/mongodbs.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/mongodbs.yaml index 519e368f68..dc0139c66b 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/mongodbs.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/mongodbs.yaml @@ -34,6 +34,7 @@ spec: create: Never displayMode: List fieldPath: '{.response.dashboards[0].panels}' + impersonate: true kind: Connection name: Dashboards query: @@ -137,6 +138,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/mysqls.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/mysqls.yaml index 7117d93744..c840698a30 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/mysqls.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/mysqls.yaml @@ -31,6 +31,7 @@ spec: create: Never displayMode: List fieldPath: '{.response.dashboards[0].panels}' + impersonate: true kind: Connection name: Dashboards query: @@ -134,6 +135,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/perconaxtradbs.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/perconaxtradbs.yaml index 34a8141794..fb1630a7d2 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/perconaxtradbs.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/perconaxtradbs.yaml @@ -31,6 +31,7 @@ spec: create: Never displayMode: List fieldPath: '{.response.dashboards[0].panels}' + impersonate: true kind: Connection name: Dashboards query: @@ -152,6 +153,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/pgbouncers.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/pgbouncers.yaml index 8ee64011fd..f942dddf9a 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/pgbouncers.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/pgbouncers.yaml @@ -31,6 +31,7 @@ spec: create: Never displayMode: List fieldPath: '{.response.dashboards[0].panels}' + impersonate: true kind: Connection name: Dashboards query: @@ -152,6 +153,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/postgreses.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/postgreses.yaml index 0543df47d8..2f02373aa3 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/postgreses.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/postgreses.yaml @@ -31,6 +31,7 @@ spec: create: Never displayMode: List fieldPath: '{.response.dashboards[0].panels}' + impersonate: true kind: Connection name: Dashboards query: @@ -152,6 +153,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/proxysqls.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/proxysqls.yaml index aaf967fe9c..40c44e0b38 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/proxysqls.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/proxysqls.yaml @@ -31,6 +31,7 @@ spec: create: Never displayMode: List fieldPath: '{.response.dashboards[0].panels}' + impersonate: true kind: Connection name: Dashboards query: @@ -111,6 +112,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/redises.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/redises.yaml index 27e7ab11a0..5f63ced194 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/redises.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1/kubedb/redises.yaml @@ -31,6 +31,7 @@ spec: create: Never displayMode: List fieldPath: '{.response.dashboards[0].panels}' + impersonate: true kind: Connection name: Dashboards query: @@ -134,6 +135,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/clickhouses.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/clickhouses.yaml index cc98581fb6..a859e59d65 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/clickhouses.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/clickhouses.yaml @@ -80,6 +80,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/druids.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/druids.yaml index 408ecd283e..2497df4f09 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/druids.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/druids.yaml @@ -80,6 +80,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/elasticsearches.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/elasticsearches.yaml index 3cf32746f5..33bac2d0a7 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/elasticsearches.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/elasticsearches.yaml @@ -31,6 +31,7 @@ spec: create: Never displayMode: List fieldPath: '{.response.dashboards[0].panels}' + impersonate: true kind: Connection name: Dashboards query: @@ -134,6 +135,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/ferretdbs.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/ferretdbs.yaml index 0d20fbb9e3..a00a3a4859 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/ferretdbs.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/ferretdbs.yaml @@ -80,6 +80,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/kafkas.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/kafkas.yaml index 157a7e12ef..b99795905c 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/kafkas.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/kafkas.yaml @@ -80,6 +80,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/mariadbs.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/mariadbs.yaml index a50f313686..13531faf7e 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/mariadbs.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/mariadbs.yaml @@ -31,6 +31,7 @@ spec: create: Never displayMode: List fieldPath: '{.response.dashboards[0].panels}' + impersonate: true kind: Connection name: Dashboards query: @@ -134,6 +135,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/mongodbs.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/mongodbs.yaml index 5b69ec3c88..0d975b0ddc 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/mongodbs.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/mongodbs.yaml @@ -34,6 +34,7 @@ spec: create: Never displayMode: List fieldPath: '{.response.dashboards[0].panels}' + impersonate: true kind: Connection name: Dashboards query: @@ -137,6 +138,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/mssqlservers.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/mssqlservers.yaml index 81028a35ae..5a372cfeed 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/mssqlservers.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/mssqlservers.yaml @@ -80,6 +80,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/mysqls.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/mysqls.yaml index f23cd78171..b28a1dba55 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/mysqls.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/mysqls.yaml @@ -31,6 +31,7 @@ spec: create: Never displayMode: List fieldPath: '{.response.dashboards[0].panels}' + impersonate: true kind: Connection name: Dashboards query: @@ -134,6 +135,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/pgpool.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/pgpool.yaml index 17c492a500..1bf524fbe1 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/pgpool.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/pgpool.yaml @@ -80,6 +80,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/postgreses.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/postgreses.yaml index 753513b2e3..7283b6e23c 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/postgreses.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/postgreses.yaml @@ -31,6 +31,7 @@ spec: create: Never displayMode: List fieldPath: '{.response.dashboards[0].panels}' + impersonate: true kind: Connection name: Dashboards query: @@ -152,6 +153,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/proxysqls.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/proxysqls.yaml index f552524e0b..cd13c18764 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/proxysqls.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/proxysqls.yaml @@ -31,6 +31,7 @@ spec: create: Never displayMode: List fieldPath: '{.response.dashboards[0].panels}' + impersonate: true kind: Connection name: Dashboards query: @@ -111,6 +112,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/rabbitmqs.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/rabbitmqs.yaml index 7f8199ba53..bfec0b93d4 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/rabbitmqs.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/rabbitmqs.yaml @@ -80,6 +80,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/redises.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/redises.yaml index c0c54a7cb8..b8d32bc350 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/redises.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/redises.yaml @@ -31,6 +31,7 @@ spec: create: Never displayMode: List fieldPath: '{.response.dashboards[0].panels}' + impersonate: true kind: Connection name: Dashboards query: @@ -134,6 +135,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/singlestores.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/singlestores.yaml index cd08b79c58..8ebd8f617f 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/singlestores.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/singlestores.yaml @@ -80,6 +80,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/solrs.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/solrs.yaml index 01cfebf077..49a39a9926 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/solrs.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/solrs.yaml @@ -80,6 +80,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/zookeepers.yaml b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/zookeepers.yaml index c13c26937e..d6ff8d4cbe 100644 --- a/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/zookeepers.yaml +++ b/vendor/kmodules.xyz/resource-metadata/hub/resourceoutlines/kubedb.com/v1alpha2/kubedb/zookeepers.yaml @@ -80,6 +80,7 @@ spec: create: Never displayMode: List fieldPath: .response.dashboards + impersonate: true kind: Connection name: Grafana Dashboards query: diff --git a/vendor/modules.txt b/vendor/modules.txt index 97642b4951..d22d6c44f9 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -2020,7 +2020,7 @@ kmodules.xyz/authorizer/apiserver kmodules.xyz/authorizer/rbac kmodules.xyz/authorizer/rbac/helpers kmodules.xyz/authorizer/rbac/validation -# kmodules.xyz/client-go v0.30.37 +# kmodules.xyz/client-go v0.30.38-0.20241117075231-750051a8f0b9 ## explicit; go 1.22.0 kmodules.xyz/client-go kmodules.xyz/client-go/api/v1 @@ -2056,7 +2056,7 @@ kmodules.xyz/monitoring-agent-api/client kmodules.xyz/offshoot-api/api/v1 kmodules.xyz/offshoot-api/api/v2 kmodules.xyz/offshoot-api/util -# kmodules.xyz/resource-metadata v0.22.3-0.20241114091625-6c277c3fe863 +# kmodules.xyz/resource-metadata v0.22.3-0.20241117093124-a5b36fb25424 ## explicit; go 1.22.1 kmodules.xyz/resource-metadata/apis/core/install kmodules.xyz/resource-metadata/apis/core/v1alpha1