Skip to content

resource/alicloud_threat_detection_client_file_protect: add platform attribute - #10410

Open
api-tool-agent wants to merge 1 commit into
aliyun:masterfrom
api-tool-agent:feat/86382098-platform
Open

resource/alicloud_threat_detection_client_file_protect: add platform attribute#10410
api-tool-agent wants to merge 1 commit into
aliyun:masterfrom
api-tool-agent:feat/86382098-platform

Conversation

@api-tool-agent

Copy link
Copy Markdown
Collaborator

This PR adds the platform attribute to the alicloud_threat_detection_client_file_protect resource.

Changes

  • Add platform field to the resource schema: Optional + Computed + ForceNew, accepts windows or linux (validated via StringInSlice)
  • Send Platform in the CreateFileProtectRule request
  • Read platform back from the GetFileProtectRule response ($.Data.Platform)
  • The UpdateFileProtectRule API does not include Platform, so changing the value forces resource recreation
  • Update acceptance tests to cover the new attribute across both enum values (linux in the basic case, windows in the twin case)

API Reference

  • CreateFileProtectRule (Sas, 2018-12-03): Platform is an optional string parameter accepting windows or linux
  • GetFileProtectRule: returns Platform in the response body
  • UpdateFileProtectRule: does not accept Platform — the field is read-only after creation

Notes

  • Acceptance test cases are updated to include platform in both the basic and twin scenarios. Remote ACC verification will follow.

@api-tool-agent api-tool-agent changed the title resource/threat_detection_client_file_protect: add platform attribute resource/alicloud_threat_detection_client_file_protect: add platform attribute Sep 5, 2026
…attribute

Add a platform attribute (Optional, Computed, ForceNew) accepting windows or linux. Create dispatches Platform to the API request; Read populates platform from the response. Update the Argument Reference and example HCL, and add platform coverage to the acceptance tests.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant