Skip to content

Fix incorrect field name for translatedSourceIp #470

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

Closed
wants to merge 1 commit into from

Conversation

neiren484
Copy link

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"}}

@danischm danischm requested a review from seconroy July 17, 2025 09:50
@seconroy
Copy link
Collaborator

seconroy commented Jul 17, 2025

@neiren484, Thank you for opening the PR, Is your SDWAN manager version greater than 20.12?

Currently we supported 20.12 where it is defined as TranslatedSourceIp. In 20.14 this is updated to translatedSourceIp and we are currently working to add support for this change in PR #464 aligning to issue #426. We aim to have this fix included in the next release.

@neiren484
Copy link
Author

@seconroy
yes, M testing with 20.15. Thanks for the info.

@neiren484 neiren484 closed this Jul 17, 2025
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