Skip to content

Instantly share code, notes, and snippets.

@manics
Created October 7, 2023 13:03
Show Gist options
  • Save manics/67efaed42d25cc1f830e0d5566652b03 to your computer and use it in GitHub Desktop.
Save manics/67efaed42d25cc1f830e0d5566652b03 to your computer and use it in GitHub Desktop.
Kubernetes Netshoot with host mount Daemonset
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: netshoot
spec:
selector:
matchLabels:
name: netshoot
template:
metadata:
labels:
name: netshoot
spec:
containers:
- command:
- sleep
args:
- 365d
image: docker.io/nicolaka/netshoot:latest
imagePullPolicy: IfNotPresent
name: netshoot
securityContext:
privileged: true
volumeMounts:
- mountPath: /host
name: host-root
tolerations:
- effect: NoSchedule
key: hub.jupyter.org/dedicated
operator: Equal
value: user
- effect: NoSchedule
key: hub.jupyter.org_dedicated
operator: Equal
value: user
volumes:
- hostPath:
path: /
type: Directory
name: host-root
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment