Update resource in deployment manifests with G/V/R format (#332)

Signed-off-by: Prasad Ghangal <prasad.ghangal@gmail.com>

##### ISSUE TYPE

 - Bug fix Pull Request

##### SUMMARY

Update resource in deployment manifests with G/V/R format

Fixes #331
This commit is contained in:
Prasad Ghangal 2020-09-07 22:58:55 +05:30 committed by GitHub
parent c326015ec0
commit 085bd73dbf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 58 additions and 54 deletions

View File

@ -16,8 +16,9 @@ data:
resource_config.yaml: |
## Resources you want to watch
resources:
- name: pod # Name of the resources e.g pod, deployment, ingress, etc. (Resource name must be in singular form)
namespaces:
- name: v1/pods # Name of the resource. Resource name must be in group/version/resource (G/V/R) format
# resource name should be plural (e.g apps/v1/deployments, v1/pods)
namespaces: # List of namespaces, "all" will watch all the namespaces
include:
- all
ignore: # List of namespaces to be ignored (omitempty), used only with include: all
@ -26,7 +27,7 @@ data:
- create
- delete
- error
- name: service
- name: v1/services
namespaces:
include:
- all
@ -36,7 +37,7 @@ data:
- create
- delete
- error
- name: deployment
- name: apps/v1/deployments
namespaces:
include:
- all
@ -52,7 +53,7 @@ data:
fields:
- spec.template.spec.containers[*].image
- status.availableReplicas
- name: statefulset
- name: apps/v1/statefulsets
namespaces:
include:
- all
@ -68,7 +69,7 @@ data:
fields:
- spec.template.spec.containers[*].image
- status.readyReplicas
- name: ingress
- name: networking.k8s.io/v1beta1/ingresses
namespaces:
include:
- all
@ -78,7 +79,7 @@ data:
- create
- delete
- error
- name: node
- name: v1/nodes
namespaces:
include:
- all
@ -88,7 +89,7 @@ data:
- create
- delete
- error
- name: namespace
- name: v1/namespaces
namespaces:
include:
- all
@ -98,7 +99,7 @@ data:
- create
- delete
- error
- name: persistentvolume
- name: v1/persistentvolumes
namespaces:
include:
- all
@ -108,7 +109,7 @@ data:
- create
- delete
- error
- name: persistentvolumeclaim
- name: v1/persistentvolumeclaims
namespaces:
include:
- all
@ -118,7 +119,7 @@ data:
- create
- delete
- error
- name: configmap
- name: v1/configmaps
namespaces:
include:
- all
@ -128,7 +129,7 @@ data:
- create
- delete
- error
- name: daemonset
- name: apps/v1/daemonsets
namespaces:
include:
- all
@ -144,7 +145,7 @@ data:
fields:
- spec.template.spec.containers[*].image
- status.numberReady
- name: job
- name: batch/v1/jobs
namespaces:
include:
- all
@ -160,7 +161,7 @@ data:
fields:
- spec.template.spec.containers[*].image
- status.conditions[*].type
- name: role
- name: rbac.authorization.k8s.io/v1/roles
namespaces:
include:
- all
@ -170,7 +171,7 @@ data:
- create
- delete
- error
- name: rolebinding
- name: rbac.authorization.k8s.io/v1/rolebindings
namespaces:
include:
- all
@ -180,7 +181,7 @@ data:
- create
- delete
- error
- name: clusterrole
- name: rbac.authorization.k8s.io/v1/clusterrolebindings
namespaces:
include:
- all
@ -190,7 +191,7 @@ data:
- create
- delete
- error
- name: clusterrolebinding
- name: rbac.authorization.k8s.io/v1/clusterroles
namespaces:
include:
- all

View File

@ -16,8 +16,9 @@ data:
resource_config.yaml: |
## Resources you want to watch
resources:
- name: pod # Name of the resources e.g pod, deployment, ingress, etc. (Resource name must be in singular form)
namespaces:
- name: v1/pods # Name of the resource. Resource name must be in group/version/resource (G/V/R) format
# resource name should be plural (e.g apps/v1/deployments, v1/pods)
namespaces: # List of namespaces, "all" will watch all the namespaces
include:
- all
ignore: # List of namespaces to be ignored (omitempty), used only with include: all
@ -26,7 +27,7 @@ data:
- create
- delete
- error
- name: service
- name: v1/services
namespaces:
include:
- all
@ -36,7 +37,7 @@ data:
- create
- delete
- error
- name: deployment
- name: apps/v1/deployments
namespaces:
include:
- all
@ -52,7 +53,7 @@ data:
fields:
- spec.template.spec.containers[*].image
- status.availableReplicas
- name: statefulset
- name: apps/v1/statefulsets
namespaces:
include:
- all
@ -68,7 +69,7 @@ data:
fields:
- spec.template.spec.containers[*].image
- status.readyReplicas
- name: ingress
- name: networking.k8s.io/v1beta1/ingresses
namespaces:
include:
- all
@ -78,7 +79,7 @@ data:
- create
- delete
- error
- name: node
- name: v1/nodes
namespaces:
include:
- all
@ -88,7 +89,7 @@ data:
- create
- delete
- error
- name: namespace
- name: v1/namespaces
namespaces:
include:
- all
@ -98,7 +99,7 @@ data:
- create
- delete
- error
- name: persistentvolume
- name: v1/persistentvolumes
namespaces:
include:
- all
@ -108,7 +109,7 @@ data:
- create
- delete
- error
- name: persistentvolumeclaim
- name: v1/persistentvolumeclaims
namespaces:
include:
- all
@ -118,7 +119,7 @@ data:
- create
- delete
- error
- name: configmap
- name: v1/configmaps
namespaces:
include:
- all
@ -128,7 +129,7 @@ data:
- create
- delete
- error
- name: daemonset
- name: apps/v1/daemonsets
namespaces:
include:
- all
@ -144,7 +145,7 @@ data:
fields:
- spec.template.spec.containers[*].image
- status.numberReady
- name: job
- name: batch/v1/jobs
namespaces:
include:
- all
@ -160,7 +161,7 @@ data:
fields:
- spec.template.spec.containers[*].image
- status.conditions[*].type
- name: role
- name: rbac.authorization.k8s.io/v1/roles
namespaces:
include:
- all
@ -170,7 +171,7 @@ data:
- create
- delete
- error
- name: rolebinding
- name: rbac.authorization.k8s.io/v1/rolebindings
namespaces:
include:
- all
@ -180,7 +181,7 @@ data:
- create
- delete
- error
- name: clusterrole
- name: rbac.authorization.k8s.io/v1/clusterrolebindings
namespaces:
include:
- all
@ -190,7 +191,7 @@ data:
- create
- delete
- error
- name: clusterrolebinding
- name: rbac.authorization.k8s.io/v1/clusterroles
namespaces:
include:
- all

View File

@ -33,17 +33,18 @@ logLevel: info
config:
## Resources you want to watch
resources:
- name: pod # Name of the resources e.g pod, deployment, ingress, etc. (Resource name must be in singular form)
namespaces:
- name: v1/pods # Name of the resource. Resource name must be in group/version/resource (G/V/R) format
# resource name should be plural (e.g apps/v1/deployments, v1/pods)
namespaces: # List of namespaces, "all" will watch all the namespaces
include:
- all
ignore: # List of namespaces to be ignored (omitempty), used only with include: all
- # example : include [all], ignore [x,y,z]
- # example : include [all], ignore [x,y,z]
events: # List of lifecycle events you want to receive, e.g create, update, delete, error OR all
- create
- delete
- error
- name: service
- name: v1/services
namespaces:
include:
- all
@ -53,7 +54,7 @@ config:
- create
- delete
- error
- name: deployment
- name: apps/v1/deployments
namespaces:
include:
- all
@ -69,7 +70,7 @@ config:
fields:
- spec.template.spec.containers[*].image
- status.availableReplicas
- name: statefulset
- name: apps/v1/statefulsets
namespaces:
include:
- all
@ -85,7 +86,7 @@ config:
fields:
- spec.template.spec.containers[*].image
- status.readyReplicas
- name: ingress
- name: networking.k8s.io/v1beta1/ingresses
namespaces:
include:
- all
@ -95,7 +96,7 @@ config:
- create
- delete
- error
- name: node
- name: v1/nodes
namespaces:
include:
- all
@ -105,7 +106,7 @@ config:
- create
- delete
- error
- name: namespace
- name: v1/namespaces
namespaces:
include:
- all
@ -115,7 +116,7 @@ config:
- create
- delete
- error
- name: persistentvolume
- name: v1/persistentvolumes
namespaces:
include:
- all
@ -125,7 +126,7 @@ config:
- create
- delete
- error
- name: persistentvolumeclaim
- name: v1/persistentvolumeclaims
namespaces:
include:
- all
@ -135,7 +136,7 @@ config:
- create
- delete
- error
- name: configmap
- name: v1/configmaps
namespaces:
include:
- all
@ -145,7 +146,7 @@ config:
- create
- delete
- error
- name: daemonset
- name: apps/v1/daemonsets
namespaces:
include:
- all
@ -161,7 +162,7 @@ config:
fields:
- spec.template.spec.containers[*].image
- status.numberReady
- name: job
- name: batch/v1/jobs
namespaces:
include:
- all
@ -177,7 +178,7 @@ config:
fields:
- spec.template.spec.containers[*].image
- status.conditions[*].type
- name: role
- name: rbac.authorization.k8s.io/v1/roles
namespaces:
include:
- all
@ -187,7 +188,7 @@ config:
- create
- delete
- error
- name: rolebinding
- name: rbac.authorization.k8s.io/v1/rolebindings
namespaces:
include:
- all
@ -197,7 +198,7 @@ config:
- create
- delete
- error
- name: clusterrole
- name: rbac.authorization.k8s.io/v1/clusterrolebindings
namespaces:
include:
- all
@ -207,7 +208,7 @@ config:
- create
- delete
- error
- name: clusterrolebinding
- name: rbac.authorization.k8s.io/v1/clusterroles
namespaces:
include:
- all

View File

@ -1,7 +1,8 @@
## test_config.yaml for Integration Testing
## Resources you want to watch
resources:
- name: v1/pods # Name of the resources e.g pod, deployment, ingress, etc.
- name: v1/pods # Name of the resource. Resource name must be in group/version/resource (G/V/R) format
# resource name should be plural (e.g apps/v1/deployments, v1/pods)
namespaces: # List of namespaces, "all" will watch all the namespaces
include:
- all
@ -185,7 +186,7 @@ resources:
- create
- delete
- error
- name: rbac.authorization.k8s.io/v1/clusterrolebindings
- name: rbac.authorization.k8s.io/v1/clusterroles
namespaces:
include:
- all