diff --git a/src/K8sJanitor.WebApi/Repositories/Kubernetes/RoleRepository.cs b/src/K8sJanitor.WebApi/Repositories/Kubernetes/RoleRepository.cs index 03296eb..da75e07 100644 --- a/src/K8sJanitor.WebApi/Repositories/Kubernetes/RoleRepository.cs +++ b/src/K8sJanitor.WebApi/Repositories/Kubernetes/RoleRepository.cs @@ -212,6 +212,21 @@ public async Task CreateNamespaceFullAccessRole(string namespaceName) "*" } }, + new V1PolicyRule + { + ApiGroups = new List + { + "monitoring.coreos.com", + }, + Resources = new List + { + "servicemonitors" + }, + Verbs = new List + { + "*" + } + }, } }; try