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

Fix for the subdomain issue #19

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

sevaa
Copy link

@sevaa sevaa commented Jan 5, 2023

When an account has a domain and a subdomain underneath it, Cpanel API returns them as separate zones (e. g. test.example.com and example.com). However, it will only let you create an _acme-challenge.test.example.com record via adding _acme-challenge.test to the example.com domain - trying to add _acme-challenge to the test.example.com errors out.

This PR changes the "find the zone for this domain" logic to look for the topmost (shortest) name.

@sevaa sevaa mentioned this pull request Jan 6, 2023
@nfl001
Copy link

nfl001 commented Mar 5, 2024

I change the code according to your PR but got an issue when the TLD is like .or.jp etc..

@sevaa
Copy link
Author

sevaa commented Mar 5, 2024

Thanks for letting me know. What would you like me to do?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants