Skip to content
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

Impersonate calls to grafana dashboard #507

Merged
merged 1 commit into from
Nov 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
12 changes: 12 additions & 0 deletions apis/core/v1alpha1/openapi_generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions apis/identity/v1alpha1/openapi_generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions apis/management/v1alpha1/openapi_generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 18 additions & 0 deletions apis/meta/v1alpha1/openapi_generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions apis/node/v1alpha1/openapi_generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions apis/shared/openapi_generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions apis/shared/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
6 changes: 6 additions & 0 deletions apis/ui/v1alpha1/openapi_generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions crds/meta.k8s.appscode.com_resourceblockdefinitions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ spec:
- src
type: object
type: array
impersonate:
type: boolean
kind:
enum:
- Block
Expand Down
2 changes: 2 additions & 0 deletions crds/meta.k8s.appscode.com_resourcedescriptors.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,8 @@ spec:
type: string
connected:
properties:
impersonate:
type: boolean
query:
properties:
byLabel:
Expand Down
10 changes: 10 additions & 0 deletions crds/meta.k8s.appscode.com_resourcelayouts.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,8 @@ spec:
- src
type: object
type: array
impersonate:
type: boolean
kind:
enum:
- Block
Expand Down Expand Up @@ -321,6 +323,8 @@ spec:
- src
type: object
type: array
impersonate:
type: boolean
kind:
enum:
- Block
Expand Down Expand Up @@ -590,6 +594,8 @@ spec:
- src
type: object
type: array
impersonate:
type: boolean
kind:
enum:
- Block
Expand Down Expand Up @@ -832,6 +838,8 @@ spec:
- src
type: object
type: array
impersonate:
type: boolean
kind:
enum:
- Block
Expand Down Expand Up @@ -1110,6 +1118,8 @@ spec:
- src
type: object
type: array
impersonate:
type: boolean
kind:
enum:
- Block
Expand Down
10 changes: 10 additions & 0 deletions crds/meta.k8s.appscode.com_resourceoutlines.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,8 @@ spec:
- src
type: object
type: array
impersonate:
type: boolean
kind:
enum:
- Block
Expand Down Expand Up @@ -410,6 +412,8 @@ spec:
- src
type: object
type: array
impersonate:
type: boolean
kind:
enum:
- Block
Expand Down Expand Up @@ -681,6 +685,8 @@ spec:
- src
type: object
type: array
impersonate:
type: boolean
kind:
enum:
- Block
Expand Down Expand Up @@ -925,6 +931,8 @@ spec:
- src
type: object
type: array
impersonate:
type: boolean
kind:
enum:
- Block
Expand Down Expand Up @@ -1205,6 +1213,8 @@ spec:
- src
type: object
type: array
impersonate:
type: boolean
kind:
enum:
- Block
Expand Down
2 changes: 2 additions & 0 deletions crds/ui.k8s.appscode.com_resourcedashboards.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ spec:
type: string
connected:
properties:
impersonate:
type: boolean
query:
properties:
byLabel:
Expand Down
3 changes: 2 additions & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ require (
k8s.io/klog/v2 v2.130.1
k8s.io/kube-openapi v0.0.0-20240703190633-0aa61b46e8c2
kmodules.xyz/apiversion v0.2.0
kmodules.xyz/client-go v0.30.37
kmodules.xyz/client-go v0.30.38-0.20241117075231-750051a8f0b9
kmodules.xyz/crd-schema-fuzz v0.29.1
kmodules.xyz/go-containerregistry v0.0.12
kmodules.xyz/offshoot-api v0.30.1
Expand Down Expand Up @@ -127,6 +127,7 @@ require (
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
gotest.tools/v3 v3.1.0 // indirect
k8s.io/apiserver v0.30.2 // indirect
k8s.io/utils v0.0.0-20240502163921-fe8a2dddb1d0 // indirect
sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.4.1 // indirect
Expand Down
6 changes: 4 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -322,6 +322,8 @@ k8s.io/apiextensions-apiserver v0.30.2 h1:l7Eue2t6QiLHErfn2vwK4KgF4NeDgjQkCXtEbO
k8s.io/apiextensions-apiserver v0.30.2/go.mod h1:lsJFLYyK40iguuinsb3nt+Sj6CmodSI4ACDLep1rgjw=
k8s.io/apimachinery v0.30.2 h1:fEMcnBj6qkzzPGSVsAZtQThU62SmQ4ZymlXRC5yFSCg=
k8s.io/apimachinery v0.30.2/go.mod h1:iexa2somDaxdnj7bha06bhb43Zpa6eWH8N8dbqVjTUc=
k8s.io/apiserver v0.30.2 h1:ACouHiYl1yFI2VFI3YGM+lvxgy6ir4yK2oLOsLI1/tw=
k8s.io/apiserver v0.30.2/go.mod h1:BOTdFBIch9Sv0ypSEcUR6ew/NUFGocRFNl72Ra7wTm8=
k8s.io/client-go v0.30.2 h1:sBIVJdojUNPDU/jObC+18tXWcTJVcwyqS9diGdWHk50=
k8s.io/client-go v0.30.2/go.mod h1:JglKSWULm9xlJLx4KCkfLLQ7XwtlbflV6uFFSHTMgVs=
k8s.io/klog/v2 v2.130.1 h1:n9Xl7H1Xvksem4KFG4PYbdQCQxqc/tTUyrgXaOhHSzk=
Expand All @@ -332,8 +334,8 @@ k8s.io/utils v0.0.0-20240502163921-fe8a2dddb1d0 h1:jgGTlFYnhF1PM1Ax/lAlxUPE+KfCI
k8s.io/utils v0.0.0-20240502163921-fe8a2dddb1d0/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0=
kmodules.xyz/apiversion v0.2.0 h1:vAQYqZFm4xu4pbB1cAdHbFEPES6EQkcR4wc06xdTOWk=
kmodules.xyz/apiversion v0.2.0/go.mod h1:oPX8g8LvlPdPX3Yc5YvCzJHQnw3YF/X4/jdW0b1am80=
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/go-containerregistry v0.0.12 h1:Tl32QGmSqRVm9PUEb/f3dgDeu9zW5fVzt3qmAFIE37I=
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ spec:
create: Never
displayMode: List
fieldPath: '{.response.dashboards[0].panels}'
impersonate: true
kind: Connection
name: Dashboards
query:
Expand Down Expand Up @@ -134,6 +135,7 @@ spec:
create: Never
displayMode: List
fieldPath: .response.dashboards
impersonate: true
kind: Connection
name: Grafana Dashboards
query:
Expand Down
1 change: 1 addition & 0 deletions hub/resourceoutlines/kubedb.com/v1/kubedb/kafkas.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ spec:
create: Never
displayMode: List
fieldPath: .response.dashboards
impersonate: true
kind: Connection
name: Grafana Dashboards
query:
Expand Down
2 changes: 2 additions & 0 deletions hub/resourceoutlines/kubedb.com/v1/kubedb/mariadbs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ spec:
create: Never
displayMode: List
fieldPath: '{.response.dashboards[0].panels}'
impersonate: true
kind: Connection
name: Dashboards
query:
Expand Down Expand Up @@ -134,6 +135,7 @@ spec:
create: Never
displayMode: List
fieldPath: .response.dashboards
impersonate: true
kind: Connection
name: Grafana Dashboards
query:
Expand Down
2 changes: 2 additions & 0 deletions hub/resourceoutlines/kubedb.com/v1/kubedb/mongodbs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ spec:
create: Never
displayMode: List
fieldPath: '{.response.dashboards[0].panels}'
impersonate: true
kind: Connection
name: Dashboards
query:
Expand Down Expand Up @@ -137,6 +138,7 @@ spec:
create: Never
displayMode: List
fieldPath: .response.dashboards
impersonate: true
kind: Connection
name: Grafana Dashboards
query:
Expand Down
2 changes: 2 additions & 0 deletions hub/resourceoutlines/kubedb.com/v1/kubedb/mysqls.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ spec:
create: Never
displayMode: List
fieldPath: '{.response.dashboards[0].panels}'
impersonate: true
kind: Connection
name: Dashboards
query:
Expand Down Expand Up @@ -134,6 +135,7 @@ spec:
create: Never
displayMode: List
fieldPath: .response.dashboards
impersonate: true
kind: Connection
name: Grafana Dashboards
query:
Expand Down
2 changes: 2 additions & 0 deletions hub/resourceoutlines/kubedb.com/v1/kubedb/perconaxtradbs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ spec:
create: Never
displayMode: List
fieldPath: '{.response.dashboards[0].panels}'
impersonate: true
kind: Connection
name: Dashboards
query:
Expand Down Expand Up @@ -152,6 +153,7 @@ spec:
create: Never
displayMode: List
fieldPath: .response.dashboards
impersonate: true
kind: Connection
name: Grafana Dashboards
query:
Expand Down
2 changes: 2 additions & 0 deletions hub/resourceoutlines/kubedb.com/v1/kubedb/pgbouncers.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ spec:
create: Never
displayMode: List
fieldPath: '{.response.dashboards[0].panels}'
impersonate: true
kind: Connection
name: Dashboards
query:
Expand Down Expand Up @@ -152,6 +153,7 @@ spec:
create: Never
displayMode: List
fieldPath: .response.dashboards
impersonate: true
kind: Connection
name: Grafana Dashboards
query:
Expand Down
Loading
Loading