1004 DNS Validation Error
See original GitHub issueI’m getting this error in the log when trying to create the cnames for domain.xyz and www.domainname.xyz
container rule value: Host(domainname.xyz
,www.domainname.xyz
)
extracted_domains from rule: [u’domainname.xyz,
www.domainname.xyz’]
Found Container: 647e66db859869694c080e371cff0b9bba33e21850d439c5fe3b86a41eb818f7 with Hostname domainname.xyz,
www.domainname.xyz
** domainname.xyz,
www.domainname.xyz - 1004 DNS Validation Error
organizr container label is Host(domainname.xyz
,www.domainname.xyz
)
Issue Analytics
- State:
- Created 3 years ago
- Comments:9 (2 by maintainers)
Top Results From Across the Web
Community Tip - Fixing Code 1004: DNS Validation Error
A Code 1004 error while working on the Cloudflare dashboard indicates that Cloudflare was unable to complete a requested action. This is a ......
Read more >Error: DNS Validation Error (Code: 1004) - SendGrid Support
Users may see DNS Validation Error (Code: 1004) when using a CNAME record that is not available via the public internet. This guide...
Read more >Tips to fix cloudflare code 1004 - Bobcares
Error with the DNS records. The most common reason for the Cloudflare code 1004 is an error with the DNS record that the...
Read more >[Solved] DNS Validation Error (Code: 1004): CNAME content ...
DNS Validation Error (Code: 1004): CNAME content cannot be an IP (Code: 9040) - You are getting this error because you added you...
Read more >DNS validation error code 1004 this record type cannot be ...
DNS validation error code 1004 this record type cannot be proxied .this error happens while adding some records in your Cloudflare DNS ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Thanks that worked
I have a Host rule in the
||
format that Cloudflare Companion expects and it still throws a 1004 error when encountering my root domain. Is it possible that the code can’t parse the root domain because it doesn’t have a subdomain?My rule:
First two are parsed fine, the last one throws a 1004 error.
EDIT: I enabled debug logs and I think I see something that might cause an issue?
The curl is trying to set a CNAME record for example.com pointing to example.com. I think that’s why the errors are saying that CNAME can’t reference itself.
Probably Cloudflare Companion should just ignore any parsed hostname that is an exact match for the
TARGET_DOMAIN
environment variable.EDIT 2: I got rid of the error by changing
TARGET_DOMAIN=$DOMAIN
toTARGET_DOMAIN=ddns.$DOMAIN
. Now when it tries to create a CNAME for example.com it will point to ddns.example.com so Cloudflare won’t mind. But probably the container should still have a contingency for whenTARGET_DOMAIN
is equal to the CNAME name. If this contingency isn’t put in place then it will cause issues with #13, sinceddns
will now need to be whitelisted and ignored somehow.