Skip to content
Open
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
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,9 @@ This function implements resource-specific health checks for standard Kubernetes
- [ ] NetworkPolicy

### RBAC (rbac.authorization.k8s.io/v1)
- [ ] Role
- [x] Role - Always ready if it exists
- [ ] ClusterRole
- [ ] RoleBinding
- [x] RoleBinding - Always ready if it exists
- [ ] ClusterRoleBinding

### Storage (storage.k8s.io/v1)
Expand Down
2 changes: 2 additions & 0 deletions healthchecks/registry.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,8 @@ func init() {
registerPersistentVolumeClaimHealthCheck()
registerPodHealthCheck()
registerReplicaSetHealthCheck()
registerRoleHealthCheck()
registerRoleBindingHealthCheck()
registerSecretHealthCheck()
registerServiceHealthCheck()
registerServiceAccountHealthCheck()
Expand Down
14 changes: 14 additions & 0 deletions healthchecks/role.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
package healthchecks

import (
"k8s.io/apimachinery/pkg/runtime/schema"
)

func registerRoleHealthCheck() {
gvk := schema.GroupVersionKind{
Group: "rbac.authorization.k8s.io",
Version: "v1",
Kind: "Role",
}
RegisterHealthCheck(gvk, alwaysReady)
}
14 changes: 14 additions & 0 deletions healthchecks/rolebinding.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
package healthchecks

import (
"k8s.io/apimachinery/pkg/runtime/schema"
)

func registerRoleBindingHealthCheck() {
gvk := schema.GroupVersionKind{
Group: "rbac.authorization.k8s.io",
Version: "v1",
Kind: "RoleBinding",
}
RegisterHealthCheck(gvk, alwaysReady)
}
Loading