Skip to content

Commit

Permalink
add: SecurityContextConstraint kustomize
Browse files Browse the repository at this point in the history
  • Loading branch information
VanillaSpoon committed Oct 4, 2023
1 parent c25e61f commit f20278e
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 0 deletions.
1 change: 1 addition & 0 deletions ray-operator/config/default/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ bases:
- ../crd
- ../rbac
- ../manager
- ../scc
- namespace.yaml
# [PROMETHEUS] To enable prometheus monitor, uncomment all sections with 'PROMETHEUS'.
#- ../prometheus
Expand Down
6 changes: 6 additions & 0 deletions ray-operator/config/scc/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
resources:
- ray_operator_scc.yaml

commonLabels:
app.kubernetes.io/name: kuberay
app.kubernetes.io/component: kuberay-operator
11 changes: 11 additions & 0 deletions ray-operator/config/scc/ray_operator_scc.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
kind: SecurityContextConstraints
apiVersion: security.openshift.io/v1
metadata:
name: run-as-ray-user
seLinuxContext:
type: MustRunAs
runAsUser:
type: MustRunAs
uid: 1000
users:
- 'system:serviceaccount:$(namespace):kuberay-operator'

0 comments on commit f20278e

Please sign in to comment.