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

OCPBUGS-48469: Fix CoreDNS static pod bring-up on cloud platforms #4830

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

sadasu
Copy link
Contributor

@sadasu sadasu commented Feb 3, 2025

Fixes: OCPBUGS-48469

- What I did

  1. Updated CoreDNS Corefile errors for cloud platforms needing alternate in-cluster DNS when UserProvisionedDNS is enabled via the install-config
  2. Updated the list of directories to include the location of the CoreDNS files for cloud platforms
  3. Updated test data and unit tests for UserProvisionedDNS enabled on GCP.

- How to verify it
Set UserProvisionedDNS to Enabled for GCP via install-config and start installation

- Description for the changelog
Fixed issues with CoreDNS Corefile and template path for cloud platforms when UserProvisionedDNS is enabled.
Added test_data for GCP with all the UserProvisionedDNS configuration to better test this path.

@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Feb 3, 2025
Copy link
Contributor

openshift-ci bot commented Feb 3, 2025

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: sadasu
Once this PR has been reviewed and has the lgtm label, please assign dkhater-redhat for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found 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

@sadasu sadasu changed the title WIP: Fix dot within cloud platform coredns Corefile WIP: Fix CoreDNS static pod bring-up on cloud platforms (GCP and AWS) Feb 4, 2025
@sadasu sadasu force-pushed the fix-cloud-platform-corefile branch 2 times, most recently from 71cc2fd to 34e381d Compare February 5, 2025 17:16
@sadasu sadasu changed the title WIP: Fix CoreDNS static pod bring-up on cloud platforms (GCP and AWS) GCP: Fix issues and update tests when UserProvisionedDNS is enabled Feb 5, 2025
@openshift-ci openshift-ci bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Feb 5, 2025
@sadasu sadasu changed the title GCP: Fix issues and update tests when UserProvisionedDNS is enabled OCPBUGS-48469: Fix issues and update tests when UserProvisionedDNS is enabled Feb 5, 2025
@openshift-ci-robot openshift-ci-robot added jira/severity-critical Referenced Jira bug's severity is critical for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. labels Feb 5, 2025
@openshift-ci-robot
Copy link
Contributor

@sadasu: This pull request references Jira Issue OCPBUGS-48469, which is valid.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target version (4.19.0) matches configured target version for branch (4.19.0)
  • bug is in the state POST, which is one of the valid states (NEW, ASSIGNED, POST)

Requesting review from QA contact:
/cc @jianli-wei

The bug has been updated to refer to the pull request using the external bug tracker.

In response to this:

- What I did

- How to verify it

- Description for the changelog

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 openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci openshift-ci bot requested a review from jianli-wei February 5, 2025 17:18
@sadasu sadasu force-pushed the fix-cloud-platform-corefile branch 2 times, most recently from 513164e to 1bb98dc Compare February 5, 2025 18:33
@sadasu sadasu changed the title OCPBUGS-48469: Fix issues and update tests when UserProvisionedDNS is enabled OCPBUGS-48469: Fix CoreDNS static pod bring-up on cloud platforms when UserProvisionedDNS is enabled Feb 5, 2025
@sadasu
Copy link
Contributor Author

sadasu commented Feb 5, 2025

/label acknowledge-critical-fixes-only

@openshift-ci openshift-ci bot added the acknowledge-critical-fixes-only Indicates if the issuer of the label is OK with the policy. label Feb 5, 2025
@sadasu
Copy link
Contributor Author

sadasu commented Feb 5, 2025

/retest

// If this is a cloud platform with DNSType set to `ClusterHosted` with
// LB IPs provided, include path for their CoreDNS files
if cloudPlatformLoadBalancerIPState(*config) == availableLBIPState {
platformBasedPaths = append(platformBasedPaths, cloudPlatformAltDNS)
Copy link
Contributor

Choose a reason for hiding this comment

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

Before this, was anything processing the templates in cloud-platform-alt-dns ? Was is being done in bootstrap only?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It was being done on the Bootstrap node successfully and while debugging for the CoreDNS pod not starting on the master nodes, I found this issue.

@sadasu
Copy link
Contributor Author

sadasu commented Feb 6, 2025

/retest-required

@mkowalski
Copy link
Contributor

mkowalski commented Feb 6, 2025

Ok from on-prem team. MCO can do the honours of merging if the order of merging templates makes sense

@sadasu sadasu force-pushed the fix-cloud-platform-corefile branch from 1bb98dc to 3a4599e Compare February 7, 2025 00:55
Copy link
Contributor

@mkowalski mkowalski left a comment

Choose a reason for hiding this comment

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

One new comment for the changed invocation of runtimecfg.

Plus a test will be good. MCO has all what's needed to test if the rendered config looks good.

Comment on lines 43 to 44
- "--resolvconf-path"
- "/var/run/NetworkManager/resolv.conf"
Copy link
Contributor

@mkowalski mkowalski Feb 7, 2025

Choose a reason for hiding this comment

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

Why? Isn't passing /etc/resolv.conf enough?

We do it in Metal in case you run a scenario where /etc/resolv.conf is not ready when we run. But I don't see yet how you could have a cloud VM that does not have any DNS server configured at startup

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think /etc/resolv.conf is sufficient. I was going to ask you why /var/run/NetworkManager/resolv.conf was chosen for metal platform. Thanks for clarifying.

@sadasu sadasu changed the title OCPBUGS-48469: Fix CoreDNS static pod bring-up on cloud platforms when UserProvisionedDNS is enabled OCPBUGS-48469: Fix CoreDNS static pod bring-up on cloud platforms Feb 8, 2025
Fix issues with CoreDNS Corefile and template path for cloud platforms
when UserProvisionedDNS is enabled.
Pass in the optional parameter `--resolvconf-path` to the render
method in baremetal-runtimecfg for cloud platforms too.
The resolv.conf file would be used to populate `DNSUpstreams` in
the Corefile template.
Also add test_data containing ControllerConfig for GCP when
DNStype is `ClusterHosted` and all the LB IP values are available.
@sadasu sadasu force-pushed the fix-cloud-platform-corefile branch from 60b714b to 0060c15 Compare February 8, 2025 01:14
Copy link
Contributor

openshift-ci bot commented Feb 8, 2025

@sadasu: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/e2e-azure-ovn-upgrade-out-of-change 0060c15 link false /test e2e-azure-ovn-upgrade-out-of-change
ci/prow/okd-scos-e2e-aws-ovn 0060c15 link false /test okd-scos-e2e-aws-ovn
ci/prow/e2e-vsphere-ovn-upi-zones 0060c15 link false /test e2e-vsphere-ovn-upi-zones
ci/prow/e2e-vsphere-ovn-zones 0060c15 link false /test e2e-vsphere-ovn-zones
ci/prow/e2e-vsphere-ovn-upi 0060c15 link false /test e2e-vsphere-ovn-upi

Full PR test history. Your PR dashboard.

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-sigs/prow repository. I understand the commands that are listed here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
acknowledge-critical-fixes-only Indicates if the issuer of the label is OK with the policy. jira/severity-critical Referenced Jira bug's severity is critical for the branch this PR is targeting. jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants