Skip to content

Commit

Permalink
stub converter, generator refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
Marcin Parafiniuk committed Sep 10, 2024
1 parent 1fe0bb6 commit e602940
Show file tree
Hide file tree
Showing 14 changed files with 745 additions and 361 deletions.
8 changes: 8 additions & 0 deletions docs/data-sources/network_group_policies.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,16 @@ data "meraki_network_group_policies" "example" {

### Read-Only

- `bandwidth_bandwidth_limits_limit_down` (Number)
- `bandwidth_bandwidth_limits_limit_up` (Number)
- `bandwidth_settings` (String)
- `bonjour_forwarding_rules` (Attributes List) (see [below for nested schema](#nestedatt--bonjour_forwarding_rules))
- `bonjour_forwarding_settings` (String)
- `content_filtering_allowed_url_patterns_settings` (String)
- `content_filtering_blocked_url_categories_categories` (List of String)
- `content_filtering_blocked_url_categories_settings` (String)
- `content_filtering_blocked_url_patterns_patterns` (List of String)
- `content_filtering_blocked_url_patterns_settings` (String)

<a id="nestedatt--bonjour_forwarding_rules"></a>
### Nested Schema for `bonjour_forwarding_rules`
Expand Down
16 changes: 16 additions & 0 deletions docs/resources/network_group_policies.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,14 @@ resource "meraki_network_group_policies" "example" {
vlan_id = "2"
}
]
bandwidth_bandwidth_limits_limit_down = 1000000
bandwidth_bandwidth_limits_limit_up = 1000000
bandwidth_settings = "custom"
content_filtering_allowed_url_patterns_settings = "network default"
content_filtering_blocked_url_categories_categories = ["meraki:contentFiltering/category/1"]
content_filtering_blocked_url_categories_settings = "override"
content_filtering_blocked_url_patterns_patterns = ["http://www.betting.com"]
content_filtering_blocked_url_patterns_settings = "append"
}
```

Expand All @@ -37,8 +45,16 @@ resource "meraki_network_group_policies" "example" {

### Optional

- `bandwidth_bandwidth_limits_limit_down` (Number)
- `bandwidth_bandwidth_limits_limit_up` (Number)
- `bandwidth_settings` (String)
- `bonjour_forwarding_rules` (Attributes List) (see [below for nested schema](#nestedatt--bonjour_forwarding_rules))
- `bonjour_forwarding_settings` (String)
- `content_filtering_allowed_url_patterns_settings` (String)
- `content_filtering_blocked_url_categories_categories` (List of String)
- `content_filtering_blocked_url_categories_settings` (String)
- `content_filtering_blocked_url_patterns_patterns` (List of String)
- `content_filtering_blocked_url_patterns_settings` (String)

### Read-Only

Expand Down
8 changes: 8 additions & 0 deletions examples/resources/meraki_network_group_policies/resource.tf
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,12 @@ resource "meraki_network_group_policies" "example" {
vlan_id = "2"
}
]
bandwidth_bandwidth_limits_limit_down = 1000000
bandwidth_bandwidth_limits_limit_up = 1000000
bandwidth_settings = "custom"
content_filtering_allowed_url_patterns_settings = "network default"
content_filtering_blocked_url_categories_categories = ["meraki:contentFiltering/category/1"]
content_filtering_blocked_url_categories_settings = "override"
content_filtering_blocked_url_patterns_patterns = ["http://www.betting.com"]
content_filtering_blocked_url_patterns_settings = "append"
}
43 changes: 39 additions & 4 deletions gen/definitions/networks_group_policies.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,45 @@ attributes:
- model_name: vlanId
type: String
example: "2"




- model_name: limitDown
data_path: [bandwidth, bandwidthLimits]
type: Int64
example: 1000000
- model_name: limitUp
data_path: [bandwidth, bandwidthLimits]
type: Int64
example: 1000000
- model_name: settings
data_path: [bandwidth]
type: String
example: custom
- model_name: settings
data_path: [contentFiltering, allowedUrlPatterns]
exclude_test: true
type: String
example: network default
- model_name: categories
data_path: [contentFiltering, blockedUrlCategories]
exclude_test: true
type: List
element_type: String
example: meraki:contentFiltering/category/1
- model_name: settings
data_path: [contentFiltering, blockedUrlCategories]
exclude_test: true
example: override
type: String
- model_name: patterns
type: List
data_path: [contentFiltering, blockedUrlPatterns]
exclude_test: true
element_type: String
example: http://www.betting.com
- model_name: settings
data_path: [contentFiltering, blockedUrlPatterns]
exclude_test: true
example: append
type: String

test_prerequisites: |
data "meraki_organization" "test" {
Expand Down
Loading

0 comments on commit e602940

Please sign in to comment.