- Take me to the Video Tutorial
In this section, we will take a look at Using Runtimes in Kubernetes
.
gvisor.yaml
apiVersion: node.k8s.io/v1
kind: RuntimeClass
metadata:
name: gvisor
handler: runsc
kubectl create -f gvisor.yml
Specify a runtimeClassName in the Pod spec:
gvisor-nginx.yaml
apiVersion: v1
kind: Pod
metadata:
name: nginx
spec:
runtimeClassName: gvisor
containers:
- image: nginx
name: nginx
kubectl create -f gvisor-nginx.yaml