dns: Add note about ndots (#907)
Following https://github.com/kubevirt/kubevirt/issues/14934 We can see that when using subdomain, `nslookup vmi.subdomain` won't resolve. Reason is that despite virt-launcher has default k8s ndots:5, ndots option isn't populated to the guest, and depends on the local resolver. If desired, cloud init can be used to override ndots. - cloudInitNoCloud: userData: |- #cloud-config bootcmd: - nmcli connection modify "System eth0" ipv4.dns-options "ndots:2" - nmcli connection up "System eth0" name: cloudinitdisk Update docs about ndots effect. Signed-off-by: Or Shoval <oshoval@redhat.com>
This commit is contained in:
		
							parent
							
								
									3c71826ed6
								
							
						
					
					
						commit
						f530840e6f
					
				|  | @ -82,3 +82,7 @@ If no `spec.hostname` is set, then we fall back to the | |||
| VirtualMachineInstance name itself. The resulting DNS A-record looks | ||||
| like this then: | ||||
| `<vmi.metadata.name>.<vmi.spec.subdomain>.<vmi.metadata.namespace>.svc.cluster.local`. | ||||
| 
 | ||||
| > **Note** To resolve short names like `myvmi.mysubdomain` using search domains, the guest's `/etc/resolv.conf` must include `options ndots:2` or higher. | ||||
| > In a Linux guest if `options ndots` is not specified, the system defaults to `ndots:1` as indicated in  resolver spec](https://man7.org/linux/man-pages/man5/resolv.conf.5.html). | ||||
| > KubeVirt does not configure the guest system resolver. It can either be pre-configured in the VM image or configured at runtime using cloud-init. | ||||
		Loading…
	
		Reference in New Issue