1 개요[ | ]
- k8s privileged
- 쿠버네티스 privileged
2 PodSpec[ | ]
yaml
Copy
kind: Deployment
...
spec:
template:
spec:
initContainers:
- name: configure-sysctl
image: busybox
securityContext:
runAsUser: 0
privileged: true
command: ["sysctl", "-w", "vm.max_map_count=262144"]
yaml
Copy
kind: Deployment
...
spec:
template:
spec:
initContainers:
- name: init-sysctl
image: busybox:1.27.2
command:
- sysctl
- -w
- vm.max_map_count=262144
securityContext:
privileged: true
3 PodSecurityPolicy[ | ]
yaml
Copy
apiVersion: policy/v1beta1
kind: PodSecurityPolicy
metadata:
name: example
spec:
privileged: false # Don't allow privileged pods!
# The rest fills in some required fields.
seLinux:
rule: RunAsAny
supplementalGroups:
rule: RunAsAny
runAsUser:
rule: RunAsAny
fsGroup:
rule: RunAsAny
volumes:
- '*'
4 같이 보기[ | ]
5 참고[ | ]
편집자 Jmnote bot Jmnote
로그인하시면 댓글을 쓸 수 있습니다.