File tree 5 files changed +36
-9
lines changed
5 files changed +36
-9
lines changed Original file line number Diff line number Diff line change 6
6
# SPDX-License-Identifier: Apache-2.0
7
7
#
8
8
9
+ # Ensure GOPATH set
10
+ if command -v go > /dev/null; then
11
+ export GOPATH=${GOPATH:- $(go env GOPATH)}
12
+ else
13
+ # if go isn't installed, set default location for GOPATH
14
+ export GOPATH=" ${GOPATH:- $HOME / go} "
15
+ fi
16
+
9
17
export KATA_KSM_THROTTLER=${KATA_KSM_THROTTLER:- no}
10
18
export KATA_QEMU_DESTDIR=${KATA_QEMU_DESTDIR:- " /usr" }
11
19
export KATA_ETC_CONFIG_PATH=" /etc/kata-containers/configuration.toml"
@@ -36,14 +44,6 @@ export KATA_NET_TIMEOUT=30
36
44
37
45
source /etc/os-release || source /usr/lib/os-release
38
46
39
- # Ensure GOPATH set
40
- if command -v go > /dev/null; then
41
- export GOPATH=${GOPATH:- $(go env GOPATH)}
42
- else
43
- # if go isn't installed, set default location for GOPATH
44
- export GOPATH=" ${GOPATH:- $HOME / go} "
45
- fi
46
-
47
47
# Support Golang 1.16.x.
48
48
# By default in Golang >= 1.16 GO111MODULE is set to "on",
49
49
# some subprojects in this repo may not support "go modules",
Original file line number Diff line number Diff line change 18
18
- containerPort : 8080
19
19
command : ["python3"]
20
20
args : [ "-m", "http.server", "8080"]
21
+ securityContext :
22
+ allowPrivilegeEscalation : false
23
+ capabilities :
24
+ drop :
25
+ - ALL
26
+ runAsNonRoot : true
27
+ runAsUser : 1000
28
+ seccompProfile :
29
+ type : RuntimeDefault
21
30
runtimeClassName : kata-qemu
Original file line number Diff line number Diff line change 1
- 3.2.0-alpha3
1
+ 3.2.0-rc0
Original file line number Diff line number Diff line change 41
41
requests :
42
42
cpu : " 100m"
43
43
memory : " 250Mi"
44
+ securityContext :
45
+ allowPrivilegeEscalation : false
46
+ capabilities :
47
+ drop :
48
+ - ALL
49
+ runAsNonRoot : true
50
+ runAsUser : 1000
51
+ seccompProfile :
52
+ type : RuntimeDefault
44
53
volumes :
45
54
- name : webhook-certs
46
55
secret :
Original file line number Diff line number Diff line change @@ -57,6 +57,15 @@ check_working() {
57
57
image: quay.io/prometheus/busybox:latest
58
58
command: ["echo", "Hello Webhook"]
59
59
imagePullPolicy: IfNotPresent
60
+ securityContext:
61
+ allowPrivilegeEscalation: false
62
+ capabilities:
63
+ drop:
64
+ - ALL
65
+ runAsNonRoot: true
66
+ runAsUser: 1000
67
+ seccompProfile:
68
+ type: RuntimeDefault
60
69
EOF
61
70
local class_name=$( kubectl get -n ${WEBHOOK_NS} \
62
71
-o jsonpath=' {.spec.runtimeClassName}' pod/${hello_pod} )
You can’t perform that action at this time.
0 commit comments