Box

Allgemein

Profil

Using SCC anyuid in OKD-OpenShift » Historie » Zyklus 1

Peter Pfläging, 21.07.2021 19:52

1 1 Peter Pfläging
# OKD  Openshift SCC AnyUID
2
3
```yaml
4
apiVersion: rbac.authorization.k8s.io/v1
5
kind: RoleBinding
6
metadata:
7
  name: system:openshift:scc:anyuid
8
  namespace: mysupercoolnamespace
9
roleRef:
10
  apiGroup: rbac.authorization.k8s.io
11
  kind: ClusterRole
12
  name: system:openshift:scc:anyuid
13
subjects:
14
- kind: ServiceAccount
15
  name: default
16
  namespace: mysupercoolnamespace
17
---
18
kind: SecurityContextConstraints
19
apiVersion: security.openshift.io/v1
20
metadata:
21
  annotations:
22
    include.release.openshift.io/ibm-cloud-managed: "true"
23
    include.release.openshift.io/self-managed-high-availability: "true"
24
    include.release.openshift.io/single-node-developer: "true"
25
    kubernetes.io/description: anyuid provides all features of the restricted SCC but allows users to run with any UID and any GID.
26
    release.openshift.io/create-only: "true"
27
  name: anyuid
28
allowHostDirVolumePlugin: false
29
allowHostIPC: false
30
allowHostNetwork: false
31
allowHostPID: false
32
allowHostPorts: false
33
allowPrivilegeEscalation: true
34
allowPrivilegedContainer: false
35
allowedCapabilities: null
36
defaultAddCapabilities: null
37
fsGroup:
38
  type: RunAsAny
39
groups:
40
- system:cluster-admins
41
priority: 10
42
readOnlyRootFilesystem: false
43
requiredDropCapabilities:
44
- MKNOD
45
runAsUser:
46
  type: RunAsAny
47
seLinuxContext:
48
  type: MustRunAs
49
supplementalGroups:
50
  type: RunAsAny
51
users: []
52
volumes:
53
- configMap
54
- downwardAPI
55
- emptyDir
56
- persistentVolumeClaim
57
- projected
58
```