Skip to content

Commit

Permalink
Merge pull request #70 from dfds/feature/add-more-api-groups
Browse files Browse the repository at this point in the history
Add support for new API groups: traefik.io, external-secrets.io and monitoring.coreos.com
  • Loading branch information
avnes authored Apr 24, 2024
2 parents 58f4acf + 924c57c commit cce3686
Showing 1 changed file with 36 additions and 0 deletions.
36 changes: 36 additions & 0 deletions src/K8sJanitor.WebApi/Repositories/Kubernetes/RoleRepository.cs
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,7 @@ public async Task<string> CreateNamespaceFullAccessRole(string namespaceName)
ApiGroups = new List<string>
{
"traefik.containo.us",
"traefik.io"
},
Resources = new List<string>
{
Expand All @@ -212,6 +213,41 @@ public async Task<string> CreateNamespaceFullAccessRole(string namespaceName)
"*"
}
},
new V1PolicyRule
{
ApiGroups = new List<string>
{
"external-secrets.io"
},
Resources = new List<string>
{
"ecrauthorizationtokens",
"externalsecrets",
"fakes",
"passwords",
"secretstores",
"webhooks"
},
Verbs = new List<string>
{
"*"
}
},
new V1PolicyRule
{
ApiGroups = new List<string>
{
"monitoring.coreos.com"
},
Resources = new List<string>
{
"servicemonitors"
},
Verbs = new List<string>
{
"*"
}
},
}
};
try
Expand Down

0 comments on commit cce3686

Please sign in to comment.