Skip to content

Commit

Permalink
install: Enable iptables in a cloud-api-adaptor pod
Browse files Browse the repository at this point in the history
This patch updates the manifest of the cloud-api-adaptor
daemonset to run the iptables command it. The cloud-api-adaptor
daemonset runs in host network mode, and iptables can manage
netfilter of the network namespace of the worker node. The iptables
command needs to access a lock file and kernel modules in the host,
and this patch adds volume mounts for them.

Signed-off-by: Yohei Ueda <[email protected]>
  • Loading branch information
yoheiueda committed Aug 23, 2024
1 parent 6e87a6f commit f0fde55
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions src/cloud-api-adaptor/install/yamls/caa-pod.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,11 @@ spec:
- mountPath: /run/netns
mountPropagation: HostToContainer
name: netns
- mountPath: /run/xtables.lock
name: xtables-lock
- mountPath: /lib/modules
name: lib-modules
readOnly: true
# # setting for cloud provider external plugin
# - mountPath: /cloud-providers
# name: provider-dir
Expand All @@ -83,6 +88,14 @@ spec:
- hostPath:
path: /run/netns
name: netns
- hostPath:
path: /run/xtables.lock
type: FileOrCreate
name: xtables-lock
- hostPath:
path: /lib/modules
type: ""
name: lib-modules
# # setting for cloud provider external plugin
# - hostPath:
# path: /opt/cloud-api-adaptor/plugins
Expand Down

0 comments on commit f0fde55

Please sign in to comment.