cloudstack-terraform-provider
cloudstack-terraform-provider copied to clipboard
feat: make cidr optional for L2 networks
- Add 'type' field to cloudstack_network resource schema
- Make 'cidr' field conditionally required based on network type
- L2 networks: cidr not required, IP parameters skipped
- L3 networks: cidr required, maintains backward compatibility
- Add CustomizeDiff validation for proper type/cidr combinations
- Update parseCIDR function to handle L2 networks without cidr
- Update resource creation logic to skip IP config for L2 networks
- Update read function to detect and set network type
- Add comprehensive test coverage for L2 networks
- Update documentation with L2 and L3 usage examples
Fixes #214