@@ -3,23 +3,23 @@ language json
3
3
pattern cloudflare_terraform_v5_attribute_renames_state() {
4
4
any {
5
5
// clear out any previously defined schema bumps
6
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
6
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
7
7
$resource_type <: r"^cloudflare_.*",
8
8
$instances <: any {
9
9
contains `"schema_version": $version`=> `"schema_version": 0`
10
10
}
11
11
},
12
12
13
13
// cloudflare_api_token
14
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
14
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
15
15
$resource_type <: contains `cloudflare_api_token`,
16
16
$instances <: any {
17
17
contains `"policy": $policy` => `"policies": $policy`
18
18
}
19
19
},
20
20
21
21
// cloudflare_account_member
22
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
22
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
23
23
$resource_type <: contains `cloudflare_account_member`,
24
24
$instances <: any {
25
25
contains `"role_ids": $roles` => `"roles": $roles`,
@@ -28,23 +28,23 @@ pattern cloudflare_terraform_v5_attribute_renames_state() {
28
28
},
29
29
30
30
// cloudflare_byo_ip_prefix
31
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
31
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
32
32
$resource_type <: contains `cloudflare_byo_ip_prefix`,
33
33
$instances <: any {
34
34
contains `"advertisement": $ad` => `"advertised": $ad`
35
35
}
36
36
},
37
37
38
38
// cloudflare_hostname_tls_setting
39
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
39
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
40
40
$resource_type <: contains `cloudflare_hostname_tls_setting`,
41
41
$instances <: any {
42
42
contains `"setting": $setting` => `"setting_id": $setting`
43
43
}
44
44
},
45
45
46
46
// cloudflare_load_balancer
47
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
47
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
48
48
$resource_type <: contains `cloudflare_load_balancer`,
49
49
$instances <: any {
50
50
contains `"fallback_pool_id": $fp` => `"fallback_pool": $fp`,
@@ -53,87 +53,87 @@ pattern cloudflare_terraform_v5_attribute_renames_state() {
53
53
},
54
54
55
55
// cloudflare_queue
56
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
56
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
57
57
$resource_type <: contains `cloudflare_queue`,
58
58
$instances <: any {
59
59
contains `"name": $q` => `"queue_name": $q`
60
60
}
61
61
},
62
62
63
63
// cloudflare_r2_bucket
64
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
64
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
65
65
$resource_type <: contains `cloudflare_r2_bucket`,
66
66
$instances <: any {
67
67
contains `"location_hint": $lh` => `"location": $lh`
68
68
}
69
69
},
70
70
71
71
// cloudflare_worker_kv
72
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
72
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
73
73
$resource_type <: contains `cloudflare_worker_kv`,
74
74
$instances <: any {
75
75
contains `"key": $key` => `"key_name": $key`
76
76
}
77
77
},
78
78
79
79
// cloudflare_logpull_retention
80
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
80
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
81
81
$resource_type <: contains `cloudflare_logpull_retention`,
82
82
$instances <: any {
83
83
contains `"enabled": $flag` => `"flag": $flag`
84
84
}
85
85
},
86
86
87
87
// cloudflare_logpush_ownership_challenge
88
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
88
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
89
89
$resource_type <: contains `cloudflare_logpush_ownership_challenge`,
90
90
$instances <: any {
91
91
contains `"ownership_challenge_filename": $ocf` => `"filename": $ocf`
92
92
}
93
93
},
94
94
95
95
// cloudflare_zero_trust_tunnel_cloudflared
96
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
96
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
97
97
$resource_type <: contains `cloudflare_zero_trust_tunnel_cloudflared`,
98
98
$instances <: any {
99
99
contains `"secret": $ts` => `"tunnel_secret": $ts`
100
100
}
101
101
},
102
102
103
103
// cloudflare_zero_trust_access_short_lived_certificate
104
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
104
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
105
105
$resource_type <: contains `cloudflare_zero_trust_access_short_lived_certificate`,
106
106
$instances <: any {
107
107
contains `"application_id": $app_id` => `"app_id": $app_id`
108
108
}
109
109
},
110
110
111
111
// cloudflare_workers_secret
112
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
112
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
113
113
$resource_type <: contains `cloudflare_workers_secret`,
114
114
$instances <: any {
115
115
contains `"secret_text": $st` => `"text": $st`
116
116
}
117
117
},
118
118
119
119
// cloudflare_workers_kv
120
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
120
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
121
121
$resource_type <: contains `cloudflare_workers_kv`,
122
122
$instances <: any {
123
123
contains `"key": $kn` => `"key_name": $kn`
124
124
}
125
125
},
126
126
127
127
// cloudflare_tiered_cache
128
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
128
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
129
129
$resource_type <: contains `cloudflare_tiered_cache`,
130
130
$instances <: any {
131
131
contains `"cache_type": $ct` => `"value": $ct`
132
132
}
133
133
},
134
134
135
135
// cloudflare_zone
136
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
136
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
137
137
$resource_type <: contains `cloudflare_zone`,
138
138
$instances <: any {
139
139
contains `"zone": $z` => `"name": $z`,
@@ -146,14 +146,14 @@ pattern cloudflare_terraform_v5_attribute_renames_state() {
146
146
},
147
147
148
148
// cloudflare_access_policy & cloudflare_zero_trust_access_group
149
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
149
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
150
150
$resource_type <: contains `cloudflare_access_policy`,
151
151
$instances <: any {
152
152
contains `"application_id": $_` => .,
153
153
contains `"precedence": $_` => .,
154
154
}
155
155
},
156
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
156
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
157
157
$resource_type <: contains `cloudflare_zero_trust_access_group`,
158
158
$instances <: any {
159
159
contains `"application_id": $_` => .,
@@ -162,28 +162,28 @@ pattern cloudflare_terraform_v5_attribute_renames_state() {
162
162
},
163
163
164
164
// cloudflare_access_service_token & cloudflare_zero_trust_access_service_token
165
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
165
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
166
166
$resource_type <: contains `cloudflare_access_service_token`,
167
167
$instances <: any {
168
168
contains `"min_days_for_renewal": $_` => .,
169
169
}
170
170
},
171
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
171
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
172
172
$resource_type <: contains `cloudflare_zero_trust_access_service_token`,
173
173
$instances <: any {
174
174
contains `"min_days_for_renewal": $_` => .,
175
175
}
176
176
},
177
177
178
178
// cloudflare_tunnel & zero_trust_tunnel_cloudflared
179
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
179
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
180
180
$resource_type <: contains `cloudflare_tunnel`,
181
181
$instances <: any {
182
182
contains `"secret": $_` => .,
183
183
contains `"cname": $_` => .,
184
184
}
185
185
},
186
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
186
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
187
187
$resource_type <: contains `zero_trust_tunnel_cloudflared`,
188
188
$instances <: any {
189
189
contains `"secret": $_` => .,
@@ -192,7 +192,7 @@ pattern cloudflare_terraform_v5_attribute_renames_state() {
192
192
},
193
193
194
194
// cloudflare_record
195
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
195
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
196
196
$resource_type <: contains `cloudflare_record`,
197
197
$instances <: any {
198
198
contains `"data": [{$obj}]` => `"data": {
@@ -205,7 +205,7 @@ pattern cloudflare_terraform_v5_attribute_renames_state() {
205
205
},
206
206
207
207
// cloudflare_origin_ca_certificate
208
- `{ "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
208
+ `{ $..., "mode": "managed", "type": "$resource_type", $..., "instances":[$instances] }` where {
209
209
$resource_type <: contains `cloudflare_origin_ca_certificate`,
210
210
$instances <: any {
211
211
contains `"min_days_for_renewal": $_` => .
0 commit comments