Fix incorrect field name for translatedSourceIp #470
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi,
I encountered an error when trying to configure the nat_port_forwards block.
After reviewing the code, I noticed that the field translatedSourceIp was mistakenly written as TranslatedSourceIp.
It works fine after i changed it to translatedSourceIp in my local environment.
This PR corrects the casing to align with the expected schema.
Thanks for your work on this provider!
~ resource "sdwan_service_lan_vpn_feature" "service_lan_vpn_feature" {
id = "e844da94-eaf1-438b-9a52-4a786377091c"
name = "DC-LAN-VPN-10"
+ nat_port_forwards = [
+ {
+ nat_pool_name = 1
+ protocol = "TCP"
+ source_ip = "10.1.1.100"
+ source_port = 80
+ translate_port = 8080
+ translated_source_ip = "203.0.113.10"
},
]
~ version = 0 -> (known after apply)
# (14 unchanged attributes hidden)
}
Plan: 0 to add, 1 to change, 0 to destroy.
Do you want to perform these actions?
Terraform will perform the actions described above.
Only 'yes' will be accepted to approve.
Enter a value: yes
module.sdwan.sdwan_service_lan_vpn_feature.service_lan_vpn_feature["service-profile-datacenter-DC-LAN-VPN-10"]: Modifying... [id=e844da94-eaf1-438b-9a52-4a786377091c]
╷
│ Error: Client Error
│
│ with module.sdwan.sdwan_service_lan_vpn_feature.service_lan_vpn_feature["service-profile-datacenter-DC-LAN-VPN-10"],
│ on .terraform/modules/sdwan/sdwan_features_service.tf line 161, in resource "sdwan_service_lan_vpn_feature" "service_lan_vpn_feature":
│ 161: resource "sdwan_service_lan_vpn_feature" "service_lan_vpn_feature" {
│
│ Failed to configure object (PUT), got error: HTTP Request failed: StatusCode 400, {"error":{"message":"Invalid Json Payload Input","code":"SCHVALID0001","details":"{"Validation Errors":{"Required But Missing
│ Attributes":["data.natPortForward[0].translatedSourceIp"],"Not Defined In Schema Attributes":["data.natPortForward[0].TranslatedSourceIp"]}}","type":"error"}}