Skip to content

Commit

Permalink
feat: log namespace watching
Browse files Browse the repository at this point in the history
  • Loading branch information
ElderMatt committed Jun 20, 2024
1 parent a0879fd commit 6c9f3a4
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/operator/keycloak.ts
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,7 @@ export default class MyOperator extends Operator {
await this.watchResource('', 'v1', 'namespaces', async (e) => {
const { object }: { object: k8s.V1Pod } = e
const { metadata } = object
console.log('namespace: ', object.metadata)
// Check if namespace starts with prefix 'team-'
if (metadata && !metadata.name?.startsWith('team-')) return
if (metadata && metadata.name === 'team-admin') return
Expand Down

0 comments on commit 6c9f3a4

Please sign in to comment.