|
| 1 | +// Module included in the following assemblies: |
| 2 | +// |
| 3 | +// * networking/external_dns_operator/nw-creating-dns-records-on-infoblox.adoc |
| 4 | + |
| 5 | +:_content-type: PROCEDURE |
| 6 | +[id="nw-control-dns-records-public-dns-zone-infoblox_{context}"] |
| 7 | += Creating DNS records on a public DNS zone on Infoblox |
| 8 | + |
| 9 | +You can create DNS records on a public DNS zone on Infoblox by using the Red Hat External DNS Operator. |
| 10 | + |
| 11 | +.Prerequisites |
| 12 | + |
| 13 | +* You have access to the OpenShift CLI (`oc`). |
| 14 | +* You have access to the Infoblox UI. |
| 15 | +
|
| 16 | +.Procedure |
| 17 | + |
| 18 | +. Create a `secret` object with Infoblox credentials by running the following command: |
| 19 | ++ |
| 20 | +[source,terminal] |
| 21 | +---- |
| 22 | +$ oc -n external-dns-operator create secret generic infoblox-credentials --from-literal=EXTERNAL_DNS_INFOBLOX_WAPI_USERNAME=<infoblox_username> --from-literal=EXTERNAL_DNS_INFOBLOX_WAPI_PASSWORD=<infoblox_password> |
| 23 | +---- |
| 24 | + |
| 25 | +. Get the routes objects to check your cluster domain by running the following command: |
| 26 | ++ |
| 27 | +[source,terminal] |
| 28 | +---- |
| 29 | +$ oc get routes --all-namespaces | grep console |
| 30 | +---- |
| 31 | ++ |
| 32 | +.Example Output |
| 33 | +[source,terminal] |
| 34 | +---- |
| 35 | +openshift-console console console-openshift-console.apps.test.example.com console https reencrypt/Redirect None |
| 36 | +openshift-console downloads downloads-openshift-console.apps.test.example.com downloads http edge/Redirect None |
| 37 | +---- |
| 38 | + |
| 39 | +. Create an `ExternalDNS` resource YAML file, for example, sample-infoblox.yaml, as follows: |
| 40 | ++ |
| 41 | +[source,yaml] |
| 42 | +---- |
| 43 | +apiVersion: externaldns.olm.openshift.io/v1beta1 |
| 44 | +kind: ExternalDNS |
| 45 | +metadata: |
| 46 | + name: sample-infoblox |
| 47 | +spec: |
| 48 | + provider: |
| 49 | + type: Infoblox |
| 50 | + infoblox: |
| 51 | + credentials: |
| 52 | + name: infoblox-credentials |
| 53 | + gridHost: ${INFOBLOX_GRID_PUBLIC_IP} |
| 54 | + wapiPort: 443 |
| 55 | + wapiVersion: "2.3.1" |
| 56 | + domains: |
| 57 | + - filterType: Include |
| 58 | + matchType: Exact |
| 59 | + name: test.example.com |
| 60 | + source: |
| 61 | + type: OpenShiftRoute |
| 62 | + openshiftRouteOptions: |
| 63 | + routerName: default |
| 64 | +---- |
| 65 | + |
| 66 | +. Create an `ExternalDNS` resource on Infoblox by running the following command: |
| 67 | ++ |
| 68 | +[source,terminal] |
| 69 | +---- |
| 70 | +$ oc create -f sample-infoblox.yaml |
| 71 | +---- |
| 72 | + |
| 73 | +. From the Infoblox UI, check the DNS records created for `console` routes: |
| 74 | + |
| 75 | +.. Click *Data Management* -> *DNS* -> *Zones*. |
| 76 | +.. Select the zone name. |
0 commit comments