Skip to content

Commit

Permalink
Merge pull request #50 from jmhardison/add-tc-agent-rolebinding
Browse files Browse the repository at this point in the history
adding role and rolebinding
  • Loading branch information
jmhardison committed Sep 29, 2023
2 parents 07a777e + 3acd8b5 commit f7e4f9f
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 0 deletions.
7 changes: 7 additions & 0 deletions apps/jetbrains/teamcity-agent/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: jetbrains

resources:
- rbac.yaml

26 changes: 26 additions & 0 deletions apps/jetbrains/teamcity-agent/rbac.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
name: teamcity:manage-agents
rules:
- apiGroups: [""]
resources: ["namespaces"]
verbs: ["list", "get"]
- apiGroups: [""]
resources: ["pods"]
verbs: ["get", "create", "list", "delete"]
- apiGroups: ["extensions", "apps"]
resources: ["deployments"]
verbs: ["list", "get"]
---
apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
name: teamcity:manage-agents
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: Role
name: teamcity:manage-agents
subjects:
- kind: ServiceAccount
name: teamcity

0 comments on commit f7e4f9f

Please sign in to comment.