@gradientedge/cdk-utils 10.2.0 → 10.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. package/README.md +11 -11
  2. package/dist/src/lib/azure/index.d.ts +0 -1
  3. package/dist/src/lib/azure/index.js +0 -1
  4. package/dist/src/lib/cloudflare/services/access/main.js +23 -23
  5. package/dist/src/lib/cloudflare/services/api-shield/main.js +11 -11
  6. package/dist/src/lib/cloudflare/services/argo/main.js +5 -5
  7. package/dist/src/lib/cloudflare/services/filter/main.js +3 -3
  8. package/dist/src/lib/cloudflare/services/firewall/main.js +3 -3
  9. package/dist/src/lib/cloudflare/services/page/main.js +7 -7
  10. package/dist/src/lib/cloudflare/services/record/main.js +3 -3
  11. package/dist/src/lib/cloudflare/services/rule-set/main.d.ts +1 -1
  12. package/dist/src/lib/cloudflare/services/rule-set/main.js +4 -5
  13. package/dist/src/lib/cloudflare/services/worker/main.js +13 -13
  14. package/dist/src/lib/cloudflare/services/zone/main.js +18 -18
  15. package/dist/src/lib/common/stack.d.ts +3 -3
  16. package/package.json +10 -18
  17. package/src/lib/azure/index.ts +0 -1
  18. package/src/lib/cloudflare/services/access/main.ts +114 -58
  19. package/src/lib/cloudflare/services/api-shield/main.ts +48 -22
  20. package/src/lib/cloudflare/services/argo/main.ts +17 -9
  21. package/src/lib/cloudflare/services/filter/main.ts +9 -5
  22. package/src/lib/cloudflare/services/firewall/main.ts +9 -5
  23. package/src/lib/cloudflare/services/page/main.ts +27 -15
  24. package/src/lib/cloudflare/services/record/main.ts +9 -5
  25. package/src/lib/cloudflare/services/rule-set/main.ts +10 -8
  26. package/src/lib/cloudflare/services/worker/main.ts +60 -29
  27. package/src/lib/cloudflare/services/zone/main.ts +75 -35
  28. package/src/lib/common/stack.ts +3 -3
  29. package/vitest.config.ts +0 -1
  30. package/dist/src/lib/azure/utils/index.d.ts +0 -19
  31. package/dist/src/lib/azure/utils/index.js +0 -19
  32. package/setup.js +0 -3
  33. package/src/lib/azure/utils/index.ts +0 -21
@@ -1,4 +1,4 @@
1
- import * as cloudflare from '@pulumi/cloudflare';
1
+ import { Zone, ZoneCacheReserve, ZoneCacheVariants, ZoneDnssec, ZoneHold, ZoneLockdown, ZoneSetting, } from '@pulumi/cloudflare';
2
2
  import * as pulumi from '@pulumi/pulumi';
3
3
  /**
4
4
  * @classdesc Provides operations on Cloudflare Zone using Pulumi
@@ -27,15 +27,15 @@ export class CloudflareZoneManager {
27
27
  createZone(id, scope, props) {
28
28
  if (!props)
29
29
  throw `Props undefined for ${id}`;
30
- return new cloudflare.Zone(id, {
30
+ return new Zone(id, {
31
31
  ...props,
32
32
  account: props.account ?? scope.props.accountId,
33
33
  name: scope.props.domainName,
34
- });
34
+ }, { parent: scope });
35
35
  }
36
36
  resolveZone(id, scope, options) {
37
37
  const name = options?.filter?.name ?? scope.props.domainName;
38
- return cloudflare.Zone.get(name, id);
38
+ return Zone.get(name, id);
39
39
  }
40
40
  /**
41
41
  * @summary Method to create a new zone cache reserve
@@ -48,10 +48,10 @@ export class CloudflareZoneManager {
48
48
  throw `Props undefined for ${id}`;
49
49
  const zoneId = props.zoneId ??
50
50
  pulumi.output(this.resolveZone(`${id}-data-zone`, scope, { filter: { name: scope.props.domainName } })).id;
51
- return new cloudflare.ZoneCacheReserve(id, {
51
+ return new ZoneCacheReserve(id, {
52
52
  ...props,
53
53
  zoneId,
54
- });
54
+ }, { parent: scope });
55
55
  }
56
56
  /**
57
57
  * @summary Method to create a new zone cache variants
@@ -64,10 +64,10 @@ export class CloudflareZoneManager {
64
64
  throw `Props undefined for ${id}`;
65
65
  const zoneId = props.zoneId ??
66
66
  pulumi.output(this.resolveZone(`${id}-data-zone`, scope, { filter: { name: scope.props.domainName } })).id;
67
- return new cloudflare.ZoneCacheVariants(id, {
67
+ return new ZoneCacheVariants(id, {
68
68
  ...props,
69
69
  zoneId,
70
- });
70
+ }, { parent: scope });
71
71
  }
72
72
  /**
73
73
  * @summary Method to create a new zone dnssec
@@ -80,10 +80,10 @@ export class CloudflareZoneManager {
80
80
  throw `Props undefined for ${id}`;
81
81
  const zoneId = props.zoneId ??
82
82
  pulumi.output(this.resolveZone(`${id}-data-zone`, scope, { filter: { name: scope.props.domainName } })).id;
83
- return new cloudflare.ZoneDnssec(id, {
83
+ return new ZoneDnssec(id, {
84
84
  ...props,
85
85
  zoneId,
86
- });
86
+ }, { parent: scope });
87
87
  }
88
88
  /**
89
89
  * @summary Method to create a new zone hold
@@ -96,10 +96,10 @@ export class CloudflareZoneManager {
96
96
  throw `Props undefined for ${id}`;
97
97
  const zoneId = props.zoneId ??
98
98
  pulumi.output(this.resolveZone(`${id}-data-zone`, scope, { filter: { name: scope.props.domainName } })).id;
99
- return new cloudflare.ZoneHold(id, {
99
+ return new ZoneHold(id, {
100
100
  ...props,
101
101
  zoneId,
102
- });
102
+ }, { parent: scope });
103
103
  }
104
104
  /**
105
105
  * @summary Method to create a new zone lockdown
@@ -112,10 +112,10 @@ export class CloudflareZoneManager {
112
112
  throw `Props undefined for ${id}`;
113
113
  const zoneId = props.zoneId ??
114
114
  pulumi.output(this.resolveZone(`${id}-data-zone`, scope, { filter: { name: scope.props.domainName } })).id;
115
- return new cloudflare.ZoneLockdown(id, {
115
+ return new ZoneLockdown(id, {
116
116
  ...props,
117
117
  zoneId,
118
- });
118
+ }, { parent: scope });
119
119
  }
120
120
  /**
121
121
  * @summary Method to create new zone dns settings
@@ -128,10 +128,10 @@ export class CloudflareZoneManager {
128
128
  throw `Props undefined for ${id}`;
129
129
  const zoneId = props.zoneId ??
130
130
  pulumi.output(this.resolveZone(`${id}-data-zone`, scope, { filter: { name: scope.props.domainName } })).id;
131
- const zoneDnsSettings = new cloudflare.ZoneSetting(id, {
131
+ const zoneDnsSettings = new ZoneSetting(id, {
132
132
  ...props,
133
133
  zoneId,
134
- });
134
+ }, { parent: scope });
135
135
  return zoneDnsSettings;
136
136
  }
137
137
  /**
@@ -145,9 +145,9 @@ export class CloudflareZoneManager {
145
145
  throw `Props undefined for ${id}`;
146
146
  const zoneId = props.zoneId ??
147
147
  pulumi.output(this.resolveZone(`${id}-data-zone`, scope, { filter: { name: scope.props.domainName } })).id;
148
- return new cloudflare.ZoneSetting(id, {
148
+ return new ZoneSetting(id, {
149
149
  ...props,
150
150
  zoneId,
151
- });
151
+ }, { parent: scope });
152
152
  }
153
153
  }
@@ -3,15 +3,15 @@ import { BaseProps } from './types.js';
3
3
  export declare abstract class BaseStack extends Construct {
4
4
  props: BaseProps;
5
5
  /**
6
- * @summary Method to determine the core CDK construct properties injected via context cdktf.json
6
+ * @summary Method to determine the core CDK construct properties injected via context json
7
7
  */
8
8
  protected abstract determineConstructProps(props: BaseProps): void;
9
9
  /**
10
- * @summary Method to determine extra cdk contexts apart from the main cdktf.json
10
+ * @summary Method to determine extra cdk contexts apart from the main json
11
11
  */
12
12
  abstract determineExtraContexts(): void;
13
13
  /**
14
- * @summary Method to determine extra cdk stage contexts apart from the main cdktf.json
14
+ * @summary Method to determine extra cdk stage contexts apart from the main json
15
15
  */
16
16
  abstract determineStageContexts(): void;
17
17
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gradientedge/cdk-utils",
3
- "version": "10.2.0",
3
+ "version": "10.4.0",
4
4
  "description": "Utilities for AWS CDK provisioning",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -27,7 +27,7 @@
27
27
  "keywords": [
28
28
  "gradientedge",
29
29
  "cdk",
30
- "cdktf",
30
+ "pulumi",
31
31
  "awscdk"
32
32
  ],
33
33
  "license": "MIT",
@@ -55,26 +55,20 @@
55
55
  "prepare": "husky"
56
56
  },
57
57
  "dependencies": {
58
- "@aws-sdk/client-secrets-manager": "^3.975.0",
59
- "@aws-sdk/credential-providers": "^3.975.0",
58
+ "@aws-sdk/client-secrets-manager": "^3.978.0",
59
+ "@aws-sdk/credential-providers": "^3.978.0",
60
60
  "@aws-sdk/types": "^3.973.1",
61
- "@cdktf/provider-aws": "^21.22.1",
62
- "@cdktf/provider-azurerm": "^14.23.1",
63
- "@cdktf/provider-cloudflare": "^13.9.1",
64
61
  "@pulumi/aws": "^7.16.0",
65
62
  "@pulumi/azure": "^6.31.0",
66
- "@pulumi/azure-native": "^3.12.1",
63
+ "@pulumi/azure-native": "^3.13.0",
67
64
  "@pulumi/cloudflare": "^6.13.0",
68
65
  "@pulumi/command": "^1.1.3",
69
- "@pulumi/pulumi": "^3.217.1",
66
+ "@pulumi/pulumi": "^3.218.0",
70
67
  "@pulumi/std": "^2.2.0",
71
68
  "@types/lodash": "^4.17.23",
72
- "@types/node": "^25.0.10",
73
- "@types/uuid": "^11.0.0",
69
+ "@types/node": "^25.1.0",
74
70
  "app-root-path": "^3.1.0",
75
71
  "aws-cdk-lib": "^2.236.0",
76
- "cdktf": "^0.21.0",
77
- "cdktf-local-exec": "^0.6.28",
78
72
  "constructs": "^10.4.5",
79
73
  "lodash": "^4.17.23",
80
74
  "moment": "^2.30.1",
@@ -86,16 +80,14 @@
86
80
  "devDependencies": {
87
81
  "@babel/core": "^7.28.6",
88
82
  "@babel/eslint-parser": "^7.28.6",
89
- "@babel/plugin-proposal-class-properties": "^7.18.6",
90
83
  "@eslint/config-array": "^0.23.0",
91
84
  "@eslint/object-schema": "^3.0.0",
92
- "@types/node": "^25.0.10",
85
+ "@types/node": "^25.1.0",
93
86
  "@typescript-eslint/eslint-plugin": "^8.54.0",
94
87
  "@typescript-eslint/parser": "^8.54.0",
95
88
  "@vitest/coverage-v8": "^4.0.18",
96
- "aws-cdk": "^2.1103.0",
89
+ "aws-cdk": "^2.1104.0",
97
90
  "better-docs": "^2.7.3",
98
- "codecov": "^3.8.3",
99
91
  "commitizen": "^4.3.1",
100
92
  "docdash": "^2.0.2",
101
93
  "dotenv": "^17.2.3",
@@ -103,7 +95,7 @@
103
95
  "eslint": "^9.39.2",
104
96
  "eslint-config-prettier": "^10.1.8",
105
97
  "eslint-plugin-import": "^2.32.0",
106
- "eslint-plugin-jsdoc": "^62.4.1",
98
+ "eslint-plugin-jsdoc": "^62.5.0",
107
99
  "husky": "^9.1.7",
108
100
  "jsdoc": "^4.0.5",
109
101
  "jsdoc-babel": "^0.5.0",
@@ -1,4 +1,3 @@
1
1
  export * from './common/index.js'
2
2
  export * from './services/index.js'
3
3
  export * from './types/index.js'
4
- export * from './utils/index.js'
@@ -1,4 +1,16 @@
1
- import * as cloudflare from '@pulumi/cloudflare'
1
+ import {
2
+ AccessRule,
3
+ ZeroTrustAccessApplication,
4
+ ZeroTrustAccessCustomPage,
5
+ ZeroTrustAccessGroup,
6
+ ZeroTrustAccessIdentityProvider,
7
+ ZeroTrustAccessMtlsCertificate,
8
+ ZeroTrustAccessPolicy,
9
+ ZeroTrustAccessServiceToken,
10
+ ZeroTrustAccessShortLivedCertificate,
11
+ ZeroTrustAccessTag,
12
+ ZeroTrustOrganization,
13
+ } from '@pulumi/cloudflare'
2
14
  import { CommonCloudflareConstruct } from '../../common/construct.js'
3
15
  import {
4
16
  AccessRuleProps,
@@ -47,12 +59,16 @@ export class CloudflareAccessManager {
47
59
  filter: { name: scope.props.domainName },
48
60
  })?.id
49
61
 
50
- return new cloudflare.ZeroTrustAccessApplication(`${id}`, {
51
- ...props,
52
- domain: `${props.domain}-${scope.props.domainName}`,
53
- name: `${props.name}-${scope.props.stage}`,
54
- zoneId,
55
- })
62
+ return new ZeroTrustAccessApplication(
63
+ `${id}`,
64
+ {
65
+ ...props,
66
+ domain: `${props.domain}-${scope.props.domainName}`,
67
+ name: `${props.name}-${scope.props.stage}`,
68
+ zoneId,
69
+ },
70
+ { parent: scope }
71
+ )
56
72
  }
57
73
 
58
74
  /**
@@ -75,10 +91,14 @@ export class CloudflareAccessManager {
75
91
  filter: { name: scope.props.domainName },
76
92
  })?.id
77
93
 
78
- return new cloudflare.ZeroTrustAccessShortLivedCertificate(`${id}`, {
79
- ...props,
80
- zoneId,
81
- })
94
+ return new ZeroTrustAccessShortLivedCertificate(
95
+ `${id}`,
96
+ {
97
+ ...props,
98
+ zoneId,
99
+ },
100
+ { parent: scope }
101
+ )
82
102
  }
83
103
 
84
104
  /**
@@ -91,11 +111,15 @@ export class CloudflareAccessManager {
91
111
  public createAccessCustomPage(id: string, scope: CommonCloudflareConstruct, props: ZeroTrustAccessCustomPageProps) {
92
112
  if (!props) throw `Props undefined for ${id}`
93
113
 
94
- return new cloudflare.ZeroTrustAccessCustomPage(`${id}`, {
95
- ...props,
96
- accountId: props.accountId ?? scope.props.accountId,
97
- name: `${props.name}-${scope.props.stage}`,
98
- })
114
+ return new ZeroTrustAccessCustomPage(
115
+ `${id}`,
116
+ {
117
+ ...props,
118
+ accountId: props.accountId ?? scope.props.accountId,
119
+ name: `${props.name}-${scope.props.stage}`,
120
+ },
121
+ { parent: scope }
122
+ )
99
123
  }
100
124
 
101
125
  /**
@@ -114,11 +138,15 @@ export class CloudflareAccessManager {
114
138
  filter: { name: scope.props.domainName },
115
139
  })?.id
116
140
 
117
- return new cloudflare.ZeroTrustAccessGroup(`${id}`, {
118
- ...props,
119
- name: `${props.name} - ${scope.props.stage.toUpperCase()}`,
120
- zoneId,
121
- })
141
+ return new ZeroTrustAccessGroup(
142
+ `${id}`,
143
+ {
144
+ ...props,
145
+ name: `${props.name} - ${scope.props.stage.toUpperCase()}`,
146
+ zoneId,
147
+ },
148
+ { parent: scope }
149
+ )
122
150
  }
123
151
 
124
152
  /**
@@ -141,12 +169,16 @@ export class CloudflareAccessManager {
141
169
  filter: { name: scope.props.domainName },
142
170
  })?.id
143
171
 
144
- return new cloudflare.ZeroTrustAccessIdentityProvider(`${id}`, {
145
- ...props,
146
- config: props.config ?? {},
147
- name: `${props.name}-${scope.props.stage}`,
148
- zoneId,
149
- })
172
+ return new ZeroTrustAccessIdentityProvider(
173
+ `${id}`,
174
+ {
175
+ ...props,
176
+ config: props.config ?? {},
177
+ name: `${props.name}-${scope.props.stage}`,
178
+ zoneId,
179
+ },
180
+ { parent: scope }
181
+ )
150
182
  }
151
183
 
152
184
  /**
@@ -169,11 +201,15 @@ export class CloudflareAccessManager {
169
201
  filter: { name: scope.props.domainName },
170
202
  })?.id
171
203
 
172
- return new cloudflare.ZeroTrustAccessMtlsCertificate(`${id}`, {
173
- ...props,
174
- name: `${props.name}-${scope.props.stage}`,
175
- zoneId,
176
- })
204
+ return new ZeroTrustAccessMtlsCertificate(
205
+ `${id}`,
206
+ {
207
+ ...props,
208
+ name: `${props.name}-${scope.props.stage}`,
209
+ zoneId,
210
+ },
211
+ { parent: scope }
212
+ )
177
213
  }
178
214
 
179
215
  /**
@@ -192,11 +228,15 @@ export class CloudflareAccessManager {
192
228
  filter: { name: scope.props.domainName },
193
229
  })?.id
194
230
 
195
- return new cloudflare.ZeroTrustOrganization(`${id}`, {
196
- ...props,
197
- name: `${props.name}-${scope.props.stage}`,
198
- zoneId,
199
- })
231
+ return new ZeroTrustOrganization(
232
+ `${id}`,
233
+ {
234
+ ...props,
235
+ name: `${props.name}-${scope.props.stage}`,
236
+ zoneId,
237
+ },
238
+ { parent: scope }
239
+ )
200
240
  }
201
241
 
202
242
  /**
@@ -209,11 +249,15 @@ export class CloudflareAccessManager {
209
249
  public createAccessPolicy(id: string, scope: CommonCloudflareConstruct, props: ZeroTrustAccessPolicyProps) {
210
250
  if (!props) throw `Props undefined for ${id}`
211
251
 
212
- return new cloudflare.ZeroTrustAccessPolicy(`${id}`, {
213
- ...props,
214
- name: `${props.name}-${scope.props.stage}`,
215
- accountId: props.accountId ?? scope.props.accountId,
216
- })
252
+ return new ZeroTrustAccessPolicy(
253
+ `${id}`,
254
+ {
255
+ ...props,
256
+ name: `${props.name}-${scope.props.stage}`,
257
+ accountId: props.accountId ?? scope.props.accountId,
258
+ },
259
+ { parent: scope }
260
+ )
217
261
  }
218
262
 
219
263
  /**
@@ -232,11 +276,15 @@ export class CloudflareAccessManager {
232
276
  filter: { name: scope.props.domainName },
233
277
  })?.id
234
278
 
235
- return new cloudflare.AccessRule(`${id}`, {
236
- ...props,
237
- zoneId,
238
- accountId: props.accountId ?? scope.props.accountId,
239
- })
279
+ return new AccessRule(
280
+ `${id}`,
281
+ {
282
+ ...props,
283
+ zoneId,
284
+ accountId: props.accountId ?? scope.props.accountId,
285
+ },
286
+ { parent: scope }
287
+ )
240
288
  }
241
289
 
242
290
  /**
@@ -259,12 +307,16 @@ export class CloudflareAccessManager {
259
307
  filter: { name: scope.props.domainName },
260
308
  })?.id
261
309
 
262
- return new cloudflare.ZeroTrustAccessServiceToken(`${id}`, {
263
- ...props,
264
- name: `${props.name}-${scope.props.stage}`,
265
- accountId: props.accountId ?? scope.props.accountId,
266
- zoneId,
267
- })
310
+ return new ZeroTrustAccessServiceToken(
311
+ `${id}`,
312
+ {
313
+ ...props,
314
+ name: `${props.name}-${scope.props.stage}`,
315
+ accountId: props.accountId ?? scope.props.accountId,
316
+ zoneId,
317
+ },
318
+ { parent: scope }
319
+ )
268
320
  }
269
321
 
270
322
  /**
@@ -277,10 +329,14 @@ export class CloudflareAccessManager {
277
329
  public createAccessTag(id: string, scope: CommonCloudflareConstruct, props: ZeroTrustAccessTagProps) {
278
330
  if (!props) throw `Props undefined for ${id}`
279
331
 
280
- return new cloudflare.ZeroTrustAccessTag(`${id}`, {
281
- ...props,
282
- name: `${props.name}-${scope.props.stage}`,
283
- accountId: props.accountId ?? scope.props.accountId,
284
- })
332
+ return new ZeroTrustAccessTag(
333
+ `${id}`,
334
+ {
335
+ ...props,
336
+ name: `${props.name}-${scope.props.stage}`,
337
+ accountId: props.accountId ?? scope.props.accountId,
338
+ },
339
+ { parent: scope }
340
+ )
285
341
  }
286
342
  }
@@ -1,4 +1,10 @@
1
- import * as cloudflare from '@pulumi/cloudflare'
1
+ import {
2
+ ApiShield,
3
+ ApiShieldOperation,
4
+ ApiShieldOperationSchemaValidationSettings,
5
+ ApiShieldSchema,
6
+ ApiShieldSchemaValidationSettings,
7
+ } from '@pulumi/cloudflare'
2
8
  import { CommonCloudflareConstruct } from '../../common/index.js'
3
9
  import {
4
10
  ApiShieldOperationProps,
@@ -39,10 +45,14 @@ export class CloudflareApiShieldManager {
39
45
  const zoneId = props.zoneId
40
46
  ? props.zoneId
41
47
  : scope.zoneManager.resolveZone(`${id}-data-zone`, scope, { filter: { name: scope.props.domainName } })?.id
42
- return new cloudflare.ApiShield(`${id}`, {
43
- ...props,
44
- zoneId,
45
- })
48
+ return new ApiShield(
49
+ `${id}`,
50
+ {
51
+ ...props,
52
+ zoneId,
53
+ },
54
+ { parent: scope }
55
+ )
46
56
  }
47
57
 
48
58
  /**
@@ -58,11 +68,15 @@ export class CloudflareApiShieldManager {
58
68
  const zoneId = props.zoneId
59
69
  ? props.zoneId
60
70
  : scope.zoneManager.resolveZone(`${id}-data-zone`, scope, { filter: { name: scope.props.domainName } })?.id
61
- return new cloudflare.ApiShieldSchema(`${id}`, {
62
- ...props,
63
- name: `${props.name}-${scope.props.stage}`,
64
- zoneId,
65
- })
71
+ return new ApiShieldSchema(
72
+ `${id}`,
73
+ {
74
+ ...props,
75
+ name: `${props.name}-${scope.props.stage}`,
76
+ zoneId,
77
+ },
78
+ { parent: scope }
79
+ )
66
80
  }
67
81
 
68
82
  /**
@@ -82,10 +96,14 @@ export class CloudflareApiShieldManager {
82
96
  const zoneId = props.zoneId
83
97
  ? props.zoneId
84
98
  : scope.zoneManager.resolveZone(`${id}-data-zone`, scope, { filter: { name: scope.props.domainName } })?.id
85
- return new cloudflare.ApiShieldSchemaValidationSettings(`${id}`, {
86
- ...props,
87
- zoneId,
88
- })
99
+ return new ApiShieldSchemaValidationSettings(
100
+ `${id}`,
101
+ {
102
+ ...props,
103
+ zoneId,
104
+ },
105
+ { parent: scope }
106
+ )
89
107
  }
90
108
 
91
109
  /**
@@ -101,10 +119,14 @@ export class CloudflareApiShieldManager {
101
119
  const zoneId = props.zoneId
102
120
  ? props.zoneId
103
121
  : scope.zoneManager.resolveZone(`${id}-data-zone`, scope, { filter: { name: scope.props.domainName } })?.id
104
- return new cloudflare.ApiShieldOperation(`${id}`, {
105
- ...props,
106
- zoneId,
107
- })
122
+ return new ApiShieldOperation(
123
+ `${id}`,
124
+ {
125
+ ...props,
126
+ zoneId,
127
+ },
128
+ { parent: scope }
129
+ )
108
130
  }
109
131
 
110
132
  /**
@@ -124,9 +146,13 @@ export class CloudflareApiShieldManager {
124
146
  const zoneId = props.zoneId
125
147
  ? props.zoneId
126
148
  : scope.zoneManager.resolveZone(`${id}-data-zone`, scope, { filter: { name: scope.props.domainName } })?.id
127
- return new cloudflare.ApiShieldOperationSchemaValidationSettings(`${id}`, {
128
- ...props,
129
- zoneId,
130
- })
149
+ return new ApiShieldOperationSchemaValidationSettings(
150
+ `${id}`,
151
+ {
152
+ ...props,
153
+ zoneId,
154
+ },
155
+ { parent: scope }
156
+ )
131
157
  }
132
158
  }
@@ -1,4 +1,4 @@
1
- import * as cloudflare from '@pulumi/cloudflare'
1
+ import { ArgoSmartRouting, ArgoTieredCaching } from '@pulumi/cloudflare'
2
2
  import { CommonCloudflareConstruct } from '../../common/index.js'
3
3
  import { ArgoSmartRoutingProps, ArgoTieredCachingProps } from './types.js'
4
4
 
@@ -33,10 +33,14 @@ export class CloudflareArgoManager {
33
33
  const zoneId = props.zoneId
34
34
  ? props.zoneId
35
35
  : scope.zoneManager.resolveZone(`${id}-data-zone`, scope, { filter: { name: scope.props.domainName } })?.id
36
- return new cloudflare.ArgoSmartRouting(`${id}`, {
37
- ...props,
38
- zoneId,
39
- })
36
+ return new ArgoSmartRouting(
37
+ `${id}`,
38
+ {
39
+ ...props,
40
+ zoneId,
41
+ },
42
+ { parent: scope }
43
+ )
40
44
  }
41
45
 
42
46
  /**
@@ -52,9 +56,13 @@ export class CloudflareArgoManager {
52
56
  const zoneId = props.zoneId
53
57
  ? props.zoneId
54
58
  : scope.zoneManager.resolveZone(`${id}-data-zone`, scope, { filter: { name: scope.props.domainName } })?.id
55
- return new cloudflare.ArgoTieredCaching(`${id}`, {
56
- ...props,
57
- zoneId,
58
- })
59
+ return new ArgoTieredCaching(
60
+ `${id}`,
61
+ {
62
+ ...props,
63
+ zoneId,
64
+ },
65
+ { parent: scope }
66
+ )
59
67
  }
60
68
  }
@@ -1,4 +1,4 @@
1
- import * as cloudflare from '@pulumi/cloudflare'
1
+ import { Filter } from '@pulumi/cloudflare'
2
2
  import { CommonCloudflareConstruct } from '../../common/index.js'
3
3
  import { FilterProps } from './types.js'
4
4
 
@@ -33,9 +33,13 @@ export class CloudflareFilterManager {
33
33
  const zoneId = props.zoneId
34
34
  ? props.zoneId
35
35
  : scope.zoneManager.resolveZone(`${id}-data-zone`, scope, { filter: { name: scope.props.domainName } })?.id
36
- return new cloudflare.Filter(`${id}`, {
37
- ...props,
38
- zoneId,
39
- })
36
+ return new Filter(
37
+ `${id}`,
38
+ {
39
+ ...props,
40
+ zoneId,
41
+ },
42
+ { parent: scope }
43
+ )
40
44
  }
41
45
  }
@@ -1,4 +1,4 @@
1
- import * as cloudflare from '@pulumi/cloudflare'
1
+ import { FirewallRule } from '@pulumi/cloudflare'
2
2
  import { CommonCloudflareConstruct } from '../../common/index.js'
3
3
  import { FirewallRuleProps } from './types.js'
4
4
 
@@ -33,9 +33,13 @@ export class CloudflareFirewallManager {
33
33
  const zoneId = props.zoneId
34
34
  ? props.zoneId
35
35
  : scope.zoneManager.resolveZone(`${id}-data-zone`, scope, { filter: { name: scope.props.domainName } })?.id
36
- return new cloudflare.FirewallRule(`${id}`, {
37
- ...props,
38
- zoneId,
39
- })
36
+ return new FirewallRule(
37
+ `${id}`,
38
+ {
39
+ ...props,
40
+ zoneId,
41
+ },
42
+ { parent: scope }
43
+ )
40
44
  }
41
45
  }