mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-01 15:58:37 +00:00
make componenetstatus root scoped
This commit is contained in:
parent
dc685dfee6
commit
262825f13d
@ -77,6 +77,7 @@ func init() {
|
|||||||
"Minion",
|
"Minion",
|
||||||
"Namespace",
|
"Namespace",
|
||||||
"PersistentVolume",
|
"PersistentVolume",
|
||||||
|
"ComponentStatus",
|
||||||
)
|
)
|
||||||
|
|
||||||
// these kinds should be excluded from the list of resources
|
// these kinds should be excluded from the list of resources
|
||||||
|
@ -90,21 +90,21 @@ func testComponentStatusData() *api.ComponentStatusList {
|
|||||||
Conditions: []api.ComponentCondition{
|
Conditions: []api.ComponentCondition{
|
||||||
{Type: api.ComponentHealthy, Status: api.ConditionTrue, Message: "ok", Error: "nil"},
|
{Type: api.ComponentHealthy, Status: api.ConditionTrue, Message: "ok", Error: "nil"},
|
||||||
},
|
},
|
||||||
ObjectMeta: api.ObjectMeta{Name: "servergood", Namespace: "test"},
|
ObjectMeta: api.ObjectMeta{Name: "servergood"},
|
||||||
}
|
}
|
||||||
|
|
||||||
bad := api.ComponentStatus{
|
bad := api.ComponentStatus{
|
||||||
Conditions: []api.ComponentCondition{
|
Conditions: []api.ComponentCondition{
|
||||||
{Type: api.ComponentHealthy, Status: api.ConditionFalse, Message: "", Error: "bad status: 500"},
|
{Type: api.ComponentHealthy, Status: api.ConditionFalse, Message: "", Error: "bad status: 500"},
|
||||||
},
|
},
|
||||||
ObjectMeta: api.ObjectMeta{Name: "serverbad", Namespace: "test"},
|
ObjectMeta: api.ObjectMeta{Name: "serverbad"},
|
||||||
}
|
}
|
||||||
|
|
||||||
unknown := api.ComponentStatus{
|
unknown := api.ComponentStatus{
|
||||||
Conditions: []api.ComponentCondition{
|
Conditions: []api.ComponentCondition{
|
||||||
{Type: api.ComponentHealthy, Status: api.ConditionUnknown, Message: "", Error: "fizzbuzz error"},
|
{Type: api.ComponentHealthy, Status: api.ConditionUnknown, Message: "", Error: "fizzbuzz error"},
|
||||||
},
|
},
|
||||||
ObjectMeta: api.ObjectMeta{Name: "serverunknown", Namespace: "test"},
|
ObjectMeta: api.ObjectMeta{Name: "serverunknown"},
|
||||||
}
|
}
|
||||||
|
|
||||||
return &api.ComponentStatusList{
|
return &api.ComponentStatusList{
|
||||||
|
Loading…
Reference in New Issue
Block a user