Skip to content

Commit f98fd17

Browse files
committed
CNV-41196: Reordering steps for configuring a DNS server
Applied QE review Added a command for obtaining FQDN Added steps for public X private DNS Fixed up step for pointing to DNS
1 parent a2babfe commit f98fd17

File tree

2 files changed

+37
-13
lines changed

2 files changed

+37
-13
lines changed

modules/virt-configuring-secondary-dns-server.adoc

Lines changed: 30 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,31 @@ The Cluster Network Addons Operator (CNAO) deploys a Domain Name Server (DNS) se
1616
1717
.Procedure
1818

19+
. Edit the `HyperConverged` CR in your default editor by running the following command:
20+
+
21+
[source,terminal,subs="attributes+"]
22+
----
23+
$ oc edit hyperconverged kubevirt-hyperconverged -n {CNVNamespace}
24+
----
25+
26+
. Enable the DNS server and monitoring components according to the following example:
27+
+
28+
[source,yaml,subs="attributes+"]
29+
----
30+
apiVersion: hco.kubevirt.io/v1beta1
31+
kind: HyperConverged
32+
metadata:
33+
name: kubevirt-hyperconverged
34+
namespace: {CNVNamespace}
35+
spec:
36+
featureGates:
37+
deployKubeSecondaryDNS: true <1>
38+
# ...
39+
----
40+
<1> Enables the DNS server
41+
42+
. Save the file and exit the editor.
43+
1944
. Create a load balancer service to expose the DNS server outside the cluster by running the `oc expose` command according to the following example:
2045
+
2146
[source,terminal,subs="attributes+"]
@@ -38,14 +63,14 @@ NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
3863
dns-lb LoadBalancer 172.30.27.5 10.46.41.94 53:31829/TCP 5s
3964
----
4065

41-
. Edit the `HyperConverged` CR in your default editor by running the following command:
66+
. Edit the `HyperConverged` CR again:
4267
+
4368
[source,terminal,subs="attributes+"]
4469
----
4570
$ oc edit hyperconverged kubevirt-hyperconverged -n {CNVNamespace}
4671
----
4772

48-
. Enable the DNS server and monitoring components according to the following example:
73+
. Add the external IP address that you previously retrieved to the `kubeSecondaryDNSNameServerIP` field in the enterprise DNS server records. For example:
4974
+
5075
[source,yaml,subs="attributes+"]
5176
----
@@ -77,16 +102,7 @@ spec:
77102
openshift.example.com
78103
----
79104
80-
. Point to the DNS server by using one of the following methods:
81-
82-
* Add the `kubeSecondaryDNSNameServerIP` value to the `resolv.conf` file on your local machine.
83-
+
84-
[NOTE]
85-
====
86-
Editing the `resolv.conf` file overwrites existing DNS settings.
87-
====
88-
89-
* Add the `kubeSecondaryDNSNameServerIP` value and the cluster FQDN to the enterprise DNS server records. For example:
105+
. Point to the DNS server. To do so, add the `kubeSecondaryDNSNameServerIP` value and the cluster FQDN to the enterprise DNS server records. For example:
90106
+
91107
[source,terminal]
92108
----
@@ -95,5 +111,6 @@ vm.<FQDN>. IN NS ns.vm.<FQDN>.
95111
+
96112
[source,terminal]
97113
----
98-
ns.vm.<FQDN>. IN A 10.46.41.94
114+
ns.vm.<FQDN>. IN A <kubeSecondaryDNSNameServerIP>
99115
----
116+

modules/virt-connecting-vm-secondarynw-using-fqdn.adoc

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,13 @@ You can access a running virtual machine (VM) attached to a secondary network in
1414
* The IP address of the VM is public.
1515
* You configured the DNS server for secondary networks.
1616
* You retrieved the fully qualified domain name (FQDN) of the cluster.
17+
+
18+
To obtain the FQDN, use the `oc get` command as follows:
19+
+
20+
[source,terminal]
21+
----
22+
$ oc get dnses.config.openshift.io cluster -o json | jq .spec.baseDomain
23+
----
1724
1825
.Procedure
1926

0 commit comments

Comments
 (0)