-
Notifications
You must be signed in to change notification settings - Fork 96
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
DXE-2796/DXE-3126 v4.1.0 terraform import TXT record with length > 255 chars #430
Comments
In other term for which reason are you trimming double quotes here?
Thx |
Thank you for rising this issue. We will investigate and update once we have some details. |
You may be interested by the WIP to try to deal with this: https://github.com/hightoxicity/terraform-provider-akamai/tree/v4.1.0-safer-double-quotes-trim I may not have understood what it should do or what is expected as behaviour:
If you can share some specs about this, I may help. |
A better attempt: master...hightoxicity:terraform-provider-akamai:v4.1.0-revamp-txt-mgmt |
Hi, any update here? Thx |
Hi @hightoxicity, Fix for this issue will be a part for upcoming release. BR, |
Where can we see the upcoming changes that will be merged into next release? Thx |
Hi @hightoxicity, Unfortunately, there is no place that we can share with you to see the upcoming changes. All changes (commits) will be available after release. BR, |
Hi @lsadlon The underlying issue here also prevented managing TXT records with length > 255 chars in terraform, not just the terraform import of it. Can we assume that the upcoming release will allow managing the long (> 255 chars) TXT records in terraform as well? BR, |
Hi @sriraamas Yes, fix is in general for handling record with length > 255 chars, not just import. BR, |
This issue should be fixed now with Akamai Terraform Provider 5.5.0 release. |
Hi there,
Conforming https://community.akamai.com/customers/s/article/How-to-set-TXT-or-SPF-record-longer-than-255-bytes-in-Authoritative-DNS?language=en_US
We have an SPF record larger than 255 that has been created in the past into the gui following previous guide and setting this exact value:
"v=DKIM1; k=rsa; p=MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAmMZAR79x/6UHyyz6INnpuDC0dAMXUqcF6xE4a0nRN8R9FXfGRYhUHIOLCYTtj0PBG39A82lQAb/IB8epeEHkiJBye7/X8Khf4NsuQd2mkJuBgmSGsDXRI9evWE7+LcyxJaiZK/qKBAzVx37iZtbw7KhKimXhq+UztjmkVJ4qTIEkqa1z467Fw3Yyrr70JDv" "0aorve7Fs94v4Lr4/NTWHi7wVLUHl6TpBhqfJir7xVupeMLCcm2pbKkMd8eyeDDhYcrKTnubiuNGO/hqw7Sjt6WoVo8srz3+cvkEPzQbw0NRN4MVUTkcr4XGQjl3C2XSD7Gmtvjrm7sPuvdYtCADGJQIDAQAB\010"
You can find the concerning record here:
But fact is that when we use:
TF_LOG=debug terraform import -var-file=tfvars/production/env.tfvars -var-file=tfvars/production/zones.tfvars 'akamai_dns_record.ak-txt-records["springcmcontracts.com#google._domainkey.springcmcontracts.com"]' "springcmcontracts.com#google._domainkey.springcmcontracts.com#TXT"
We can see there something that is populating a strange value in the state... And this is what we see in the console on the import:
- .target[0]: was cty.StringVal("\"v=DKIM1; k=rsa; p=MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAmMZAR79x/6UHyyz6INnpuDC0dAMXUqcF6xE4a0nRN8R9FXfGRYhUHIOLCYTtj0PBG39A82lQAb/IB8epeEHkiJBye7/X8Khf4NsuQd2mkJuBgmSGsDXRI9evWE7+LcyxJaiZK/qKBAzVx37iZtbw7KhKimXhq+UztjmkVJ4qTIEkqa1z467Fw3Yyrr70JDv\" \"0aorve7Fs94v4Lr4/NTWHi7wVLUHl6TpBhqfJir7xVupeMLCcm2pbKkMd8eyeDDhYcrKTnubiuNGO/hqw7Sjt6WoVo8srz3+cvkEPzQbw0NRN4MVUTkcr4XGQjl3C2XSD7Gmtvjrm7sPuvdYtCADGJQIDAQAB\\010\""), but now cty.StringVal("v=DKIM1; k=rsa; p=MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAmMZAR79x/6UHyyz6INnpuDC0dAMXUqcF6xE4a0nRN8R9FXfGRYhUHIOLCYTtj0PBG39A82lQAb/IB8epeEHkiJBye7/X8Khf4NsuQd2mkJuBgmSGsDXRI9evWE7+LcyxJaiZK/qKBAzVx37iZtbw7KhKimXhq+UztjmkVJ4qTIEkqa1z467Fw3Yyrr70JDv\" \"0aorve7Fs94v4Lr4/NTWHi7wVLUHl6TpBhqfJir7xVupeMLCcm2pbKkMd8eyeDDhYcrKTnubiuNGO/hqw7Sjt6WoVo8srz3+cvkEPzQbw0NRN4MVUTkcr4XGQjl3C2XSD7Gmtvjrm7sPuvdYtCADGJQIDAQAB\\010") - .record_sha: was cty.StringVal("cf16f39dfca9ccbe39c81aff2b039f0bef1ae2f3"), but now cty.StringVal("e06b4c3a354d07c55b13da7214ce28b32cfa2492")
This break the first double quote and the last one for some strange reason (which one, I do not know) but fact is that it is not looking what you explain into the above guide.
Here is the populated record into the state:
I think both the value and the computed sha1 are wrong into the state json file...
Terraform Version
1.5.0
Affected Resource(s)
The text was updated successfully, but these errors were encountered: