Created
May 17, 2023 13:26
-
-
Save sridhargaddam/4408ca0ac9513910c6192910d1826677 to your computer and use it in GitHub Desktop.
Spawn a DaemonSet pod to disable tx/rx offload on vxlan interfaces
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# @sridhargaddam | |
# this script spawns a daemonSet pod in a k8s cluster to disable tx/rx offloading | |
# on vx-submariner interface created by Submariner route-agents | |
--- | |
apiVersion: apps/v1 | |
kind: DaemonSet | |
metadata: | |
name: disable-offload | |
namespace: submariner-operator | |
spec: | |
selector: | |
matchLabels: | |
app: disable-offload | |
template: | |
metadata: | |
labels: | |
app: disable-offload | |
spec: | |
tolerations: | |
- operator: Exists | |
containers: | |
- name: disable-offload | |
image: quay.io/sridhargaddam/netshoot:latest | |
imagePullPolicy: IfNotPresent | |
securityContext: | |
allowPrivilegeEscalation: true | |
capabilities: | |
add: | |
- net_admin | |
drop: | |
- all | |
privileged: true | |
readOnlyRootFilesystem: false | |
runAsNonRoot: false | |
command: ["/bin/sh", "-c"] | |
args: | |
- ethtool --offload vx-submariner rx off tx off; | |
ethtool --offload vxlan-tunnel rx off tx off; | |
sleep infinity | |
restartPolicy: Always | |
securityContext: {} | |
serviceAccount: submariner-routeagent | |
serviceAccountName: submariner-routeagent | |
hostNetwork: true |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment