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

[Bug]: Doman record TTL not updated if it's the only change #510

Closed
SpareSimian opened this issue Feb 7, 2025 · 3 comments
Closed

[Bug]: Doman record TTL not updated if it's the only change #510

SpareSimian opened this issue Feb 7, 2025 · 3 comments
Labels
bug issues that report a bug

Comments

@SpareSimian
Copy link

Package

5.3.0

Expected Behavior

TTL updated when changing only the TTL of a DomainRecord

Actual Behavior

No change.

Steps to Reproduce

Create a record with default TTL. (My domain is set to 1 hour.) Issue a record update (PUT) with only the TTL changed. (I'm using 5 minutes.) The TTL in the dashboard doesn't change. I'm seeing this with both A and AAAA records. I'm using this script:

https://github.com/SpareSimian/LinodeDDNS

Error Output

No response

@SpareSimian SpareSimian added the bug issues that report a bug label Feb 7, 2025
@lgarber-akamai
Copy link
Contributor

Hey @SpareSimian, thanks for the report!

Is there any chance you could provide a sample Python script reproducing this error?

I'm using the following and everything seems to be working as expected:

client = LinodeClient(os.getenv("LINODE_TOKEN"))

domain = client.domain_create("my-domain.com", soa_email="[email protected]")

record = domain.record_create("A", target="8.8.8.8", ttl_sec=0)
record.ttl_sec = 300
record.save()

@SpareSimian
Copy link
Author

Aha, I think you spotted the bug in my script. I set the TTL in the create path but not in the update path. PEBCAK on me! I've updated my script at the above link. Sorry for the bother.

@lgarber-akamai
Copy link
Contributor

@SpareSimian No problem at all, glad you were able to get things working!

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

No branches or pull requests

2 participants