mirror of https://github.com/kubernetes/kops.git
Mount /etc/hosts in calico containers for gossip based DNS.
This commit is contained in:
parent
17487a4853
commit
5aea1d2484
|
|
@ -178,6 +178,10 @@ spec:
|
|||
- mountPath: /var/run/calico
|
||||
name: var-run-calico
|
||||
readOnly: false
|
||||
# Necessary for gossip based DNS
|
||||
- mountPath: /etc/hosts
|
||||
name: etc-hosts
|
||||
readOnly: true
|
||||
# This container installs the Calico CNI binaries
|
||||
# and CNI network config file on each node.
|
||||
- name: install-cni
|
||||
|
|
@ -208,6 +212,10 @@ spec:
|
|||
name: cni-bin-dir
|
||||
- mountPath: /host/etc/cni/net.d
|
||||
name: cni-net-dir
|
||||
# Necessary for gossip based DNS
|
||||
- mountPath: /etc/hosts
|
||||
name: etc-hosts
|
||||
readOnly: true
|
||||
volumes:
|
||||
# Used by calico/node.
|
||||
- name: lib-modules
|
||||
|
|
@ -223,6 +231,9 @@ spec:
|
|||
- name: cni-net-dir
|
||||
hostPath:
|
||||
path: /etc/cni/net.d
|
||||
- name: etc-hosts
|
||||
hostPath:
|
||||
path: /etc/hosts
|
||||
|
||||
---
|
||||
|
||||
|
|
@ -281,6 +292,16 @@ spec:
|
|||
- name: CONFIGURE_ETC_HOSTS
|
||||
value: "true"
|
||||
|
||||
volumeMounts:
|
||||
# Necessary for gossip based DNS
|
||||
- mountPath: /etc/hosts
|
||||
name: etc-hosts
|
||||
readOnly: true
|
||||
volumes:
|
||||
- name: etc-hosts
|
||||
hostPath:
|
||||
path: /etc/hosts
|
||||
|
||||
{{ if and (eq .CloudProvider "aws") (.Networking.Calico.CrossSubnet) -}}
|
||||
# This manifest installs the k8s-ec2-srcdst container, which disables
|
||||
# src/dst ip checks to allow BGP to function for calico for hosts within subnets
|
||||
|
|
|
|||
Loading…
Reference in New Issue