Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP Use DNSProvider secret ref in DNSPolicy #636

Closed
wants to merge 4 commits into from

Conversation

mikenairn
Copy link
Member

@mikenairn mikenairn commented Oct 23, 2023

closes #715

Removes the requirement for a ManagedZone to be configured for a host in order for the DNSPolicy to create dns records for it.

Implements the providerRef option for DNSPolicy, ManagedZone and DNSRecord as described here https://github.com/Kuadrant/architecture/blob/main/rfcs/0005-single-cluster-dnspolicy.md

Todo:
[] Update docs

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Oct 23, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: mikenairn

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

mikenairn added a commit to mikenairn/multi-cluster-traffic-controller that referenced this pull request Nov 15, 2023
Add TEST_MANAGED_ZONE_NAME env var to e2e test suite steps. This will be
required for
Kuadrant#636,
but adding these here now to make life easier testing that PR.
@mikenairn mikenairn mentioned this pull request Nov 15, 2023
mikenairn added a commit to mikenairn/multi-cluster-traffic-controller that referenced this pull request Nov 15, 2023
Add TEST_MANAGED_ZONE_NAME env var to e2e test suite steps. This will be
required for
Kuadrant#636,
but adding these here now to make life easier testing that PR.

Add log to show image for mgc-controller-manager and
mgc-policy-controller
mikenairn added a commit to mikenairn/multi-cluster-traffic-controller that referenced this pull request Nov 15, 2023
Add TEST_MANAGED_ZONE_NAME env var to e2e test suite steps. This will be
required for
Kuadrant#636,
but adding these here now to make life easier testing that PR.

Add log to show image for mgc-controller-manager and
mgc-policy-controller
@@ -5,6 +5,7 @@ on:
branches:
- main
- "release-*"
- 406_dnspolicy_provider_ref
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ToDo Remove this before merge

Removes the requirement for a ManagedZone to be configured for a host in
order for the DNSPolicy to create dns records for it.

Make DNSRecord.zoneID optional Set specific allowed values for
providerRef.Kind
Allow a providerRef.Kind of ManagedZone that looks up zones from
Managedzones in the current ns (Current behaviour) and loads dns client
through the managed zone providerRef.  Add logic around zoneAssignment
in dnsPolicy, some providerRef.kinds will result in zoneAssignment being
false which indicates that a zone is not going to be looked up or
assigned to any created DNSRecords. A DNSRecord will be created for all
listeners in this case.

Created a v1alpha2 API for DNSPolicy, ManagedZone and DNSRecord.
v1alpha1 versions are removed and no longer supported.

E2E Test Updates

* DO NOT MERGE Add 406_dnspolicy_provider_ref branch for testing
* Add e2e test for dnspolicy focused on istio gateways and providers
* Add suite id and generate a testDomainName to use for all tests in
  that instance of the suite (Avoids thigns like wildcard hosts being
created that coudl affect all instances of a suite running in teh same
hosted zone)
* Removed all references to managed zones as input to the e2e test
  suite. Env vars required now are TEST_DNS_ZONE_DOMAIN_NAME,
TEST_DNS_ZONE_ID and TEST_DNS_PROVIDER_SECRET_NAME.

ManagedZone updates

* Make description optional
* fix managedZoneListToZoneList - use range index
* Make ID and description pointers
* Remove hostedzone prefix from AWS hosted zones
* Use status id in managedZoneListToZoneList
@mikenairn mikenairn changed the title Use DNSProvider secret ref in DNSPolicy WIP Use DNSProvider secret ref in DNSPolicy Jan 25, 2024
@mikenairn
Copy link
Member Author

/hold

Will come back to these changes after #780 is merged, or when all DNS code is moved to it's new repo.

@openshift-merge-robot
Copy link
Collaborator

PR needs rebase.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@mikenairn
Copy link
Member Author

/close

This PR will need to be considerably reworked. Closing for now.

@mikenairn mikenairn closed this Feb 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

DNSPolicy remove need for ManagedZone
3 participants