Skip to content

Commit

Permalink
Create templates with host ToolchainCluster-related manifests (#974)
Browse files Browse the repository at this point in the history
* add toolchaincluster SA templates

---------
Co-authored-by: Matous Jobanek <mjobanek@redhat.com>
  • Loading branch information
mfrancisc authored Mar 5, 2024
1 parent 19f31b4 commit 4875b0f
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 0 deletions.
3 changes: 3 additions & 0 deletions deploy/resources.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,6 @@ import "embed"

//go:embed templates/notificationtemplates/*
var NotificationTemplateFS embed.FS

//go:embed templates/toolchaincluster/*
var ToolchainClusterTemplateFS embed.FS
32 changes: 32 additions & 0 deletions deploy/templates/toolchaincluster/host-sa.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
---
apiVersion: v1
kind: ServiceAccount
metadata:
name: toolchaincluster-host
namespace: {{.Namespace}}
---
kind: Role
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: toolchaincluster-host
namespace: {{.Namespace}}
rules:
- apiGroups:
- toolchain.dev.openshift.com
resources:
- "*"
verbs:
- "*"
---
kind: RoleBinding
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: toolchaincluster-host
namespace: {{.Namespace}}
subjects:
- kind: ServiceAccount
name: toolchaincluster-host
roleRef:
kind: Role
name: toolchaincluster-host
apiGroup: rbac.authorization.k8s.io

0 comments on commit 4875b0f

Please sign in to comment.