Skip to content

Commit

Permalink
add .spec.subgroups field in ResourceGroup CRD
Browse files Browse the repository at this point in the history
  • Loading branch information
Liujingfang1 committed Jan 6, 2021
1 parent 76810ac commit 1e65e29
Show file tree
Hide file tree
Showing 3 changed files with 312 additions and 10 deletions.
83 changes: 79 additions & 4 deletions pkg/live/example-resource-group-crd-for-v1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,31 @@ spec:
type: string
type: object
resources:
description: Resources contains a list of resources that form the
resource group
description: Resources contains a list of resources that form the resource
group
items:
description: ObjMetadata organizes and stores the identifying information
for an object. This struct (as a string) is stored in a grouping
object to keep track of sets of applied objects.
properties:
group:
type: string
kind:
type: string
name:
type: string
namespace:
type: string
required:
- group
- kind
- name
- namespace
type: object
type: array
subgroups:
description: subgroups contains a list of sub groups that the current
group includes.
items:
description: ObjMetadata organizes and stores the identifying information
for an object. This struct (as a string) is stored in a grouping
Expand Down Expand Up @@ -153,8 +176,60 @@ spec:
items:
properties:
lastTransitionTime:
description: last time the condition transit from one
status to another
description: last time the condition transit from one status
to another
format: date-time
type: string
message:
description: human-readable message indicating details about
last transition
type: string
reason:
description: one-word CamelCase reason for the condition’s
last transition
type: string
status:
description: Status of the condition
type: string
type:
description: Type of the condition
type: string
required:
- status
- type
type: object
type: array
group:
type: string
kind:
type: string
name:
type: string
namespace:
type: string
status:
description: Status describes the status of a resource
type: string
required:
- group
- kind
- name
- namespace
- status
type: object
type: array
subgroupStatuses:
description: subgroupStatuses lists the status for each subgroup.
items:
description: ResourceStatus contains the status of a given resource
uniquely identified by its group, kind, name and namespace.
properties:
conditions:
items:
properties:
lastTransitionTime:
description: last time the condition transit from one status
to another
format: date-time
type: string
message:
Expand Down
78 changes: 77 additions & 1 deletion pkg/live/example-resource-group-crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,31 @@ spec:
type: string
type: object
resources:
description: Resources contains a list of resources that form the resource group
description: Resources contains a list of resources that form the resource
group
items:
description: ObjMetadata organizes and stores the identifying information
for an object. This struct (as a string) is stored in a grouping
object to keep track of sets of applied objects.
properties:
group:
type: string
kind:
type: string
name:
type: string
namespace:
type: string
required:
- group
- kind
- name
- namespace
type: object
type: array
subgroups:
description: subgroups contains a list of sub groups that the current
group includes.
items:
description: ObjMetadata organizes and stores the identifying information
for an object. This struct (as a string) is stored in a grouping
Expand Down Expand Up @@ -196,6 +220,58 @@ spec:
- status
type: object
type: array
subgroupStatuses:
description: subgroupStatuses lists the status for each subgroup.
items:
description: ResourceStatus contains the status of a given resource
uniquely identified by its group, kind, name and namespace.
properties:
conditions:
items:
properties:
lastTransitionTime:
description: last time the condition transit from one status
to another
format: date-time
type: string
message:
description: human-readable message indicating details about
last transition
type: string
reason:
description: one-word CamelCase reason for the condition’s
last transition
type: string
status:
description: Status of the condition
type: string
type:
description: Type of the condition
type: string
required:
- status
- type
type: object
type: array
group:
type: string
kind:
type: string
name:
type: string
namespace:
type: string
status:
description: Status describes the status of a resource
type: string
required:
- group
- kind
- name
- namespace
- status
type: object
type: array
required:
- observedGeneration
type: object
Expand Down
161 changes: 156 additions & 5 deletions pkg/live/inventoryrg.go
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,31 @@ spec:
type: string
type: object
resources:
description: Resources contains a list of resources that form the resource group
description: Resources contains a list of resources that form the resource
group
items:
description: ObjMetadata organizes and stores the identifying information
for an object. This struct (as a string) is stored in a grouping
object to keep track of sets of applied objects.
properties:
group:
type: string
kind:
type: string
name:
type: string
namespace:
type: string
required:
- group
- kind
- name
- namespace
type: object
type: array
subgroups:
description: subgroups contains a list of sub groups that the current
group includes.
items:
description: ObjMetadata organizes and stores the identifying information
for an object. This struct (as a string) is stored in a grouping
Expand Down Expand Up @@ -467,6 +491,58 @@ spec:
- status
type: object
type: array
subgroupStatuses:
description: subgroupStatuses lists the status for each subgroup.
items:
description: ResourceStatus contains the status of a given resource
uniquely identified by its group, kind, name and namespace.
properties:
conditions:
items:
properties:
lastTransitionTime:
description: last time the condition transit from one status
to another
format: date-time
type: string
message:
description: human-readable message indicating details about
last transition
type: string
reason:
description: one-word CamelCase reason for the condition’s
last transition
type: string
status:
description: Status of the condition
type: string
type:
description: Type of the condition
type: string
required:
- status
- type
type: object
type: array
group:
type: string
kind:
type: string
name:
type: string
namespace:
type: string
status:
description: Status describes the status of a resource
type: string
required:
- group
- kind
- name
- namespace
- status
type: object
type: array
required:
- observedGeneration
type: object
Expand Down Expand Up @@ -558,8 +634,31 @@ spec:
type: string
type: object
resources:
description: Resources contains a list of resources that form the
resource group
description: Resources contains a list of resources that form the resource
group
items:
description: ObjMetadata organizes and stores the identifying information
for an object. This struct (as a string) is stored in a grouping
object to keep track of sets of applied objects.
properties:
group:
type: string
kind:
type: string
name:
type: string
namespace:
type: string
required:
- group
- kind
- name
- namespace
type: object
type: array
subgroups:
description: subgroups contains a list of sub groups that the current
group includes.
items:
description: ObjMetadata organizes and stores the identifying information
for an object. This struct (as a string) is stored in a grouping
Expand Down Expand Up @@ -631,8 +730,60 @@ spec:
items:
properties:
lastTransitionTime:
description: last time the condition transit from one
status to another
description: last time the condition transit from one status
to another
format: date-time
type: string
message:
description: human-readable message indicating details about
last transition
type: string
reason:
description: one-word CamelCase reason for the condition’s
last transition
type: string
status:
description: Status of the condition
type: string
type:
description: Type of the condition
type: string
required:
- status
- type
type: object
type: array
group:
type: string
kind:
type: string
name:
type: string
namespace:
type: string
status:
description: Status describes the status of a resource
type: string
required:
- group
- kind
- name
- namespace
- status
type: object
type: array
subgroupStatuses:
description: subgroupStatuses lists the status for each subgroup.
items:
description: ResourceStatus contains the status of a given resource
uniquely identified by its group, kind, name and namespace.
properties:
conditions:
items:
properties:
lastTransitionTime:
description: last time the condition transit from one status
to another
format: date-time
type: string
message:
Expand Down

0 comments on commit 1e65e29

Please sign in to comment.