Hardcode nfs service cluster ip

So that on a delete & recreate of the service the previous pv's still
point to this nfs-provisioner. We cannot use the hostname since the actual
host doesn't know how to resolve service addresses inside of the cluster.

To support this would require the installation of kube-dns and
modification to the /etc/resolve.conf file on each host.

Signed-off-by: Joshua Moody <joshua.moody@rancher.com>
This commit is contained in:
Joshua Moody 2020-06-16 16:01:50 -07:00 committed by Sheng Yang
parent f70ee1063d
commit 23f9cc18b3

View File

@ -10,6 +10,10 @@ metadata:
labels:
app: longhorn-nfs-provisioner
spec:
# hardcode a cluster ip for the service
# so that on delete & recreate of the service the previous pv's still point
# to this nfs-provisioner, pick a new ip for each new nfs provisioner
clusterIP: 10.43.111.111
ports:
- name: nfs
port: 2049