cdk-mwaa 0.0.2__py3-none-any.whl → 0.0.4__py3-none-any.whl

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.
cdk_mwaa/__init__.py CHANGED
@@ -25,6 +25,7 @@ yarn add cdk-mwaa
25
25
  Here is an example of how to use the `cdk-mwaa` construct library in your AWS CDK project:
26
26
 
27
27
  ```python
28
+ import * as path from 'node:path';
28
29
  import * as cdk from 'aws-cdk-lib';
29
30
  import * as mwaa from 'cdk-mwaa';
30
31
 
@@ -33,11 +34,15 @@ const stack = new cdk.Stack(app, 'MwaaStack');
33
34
 
34
35
  const dagStorage = new mwaa.DagStorage(stack, 'MyMwaaDagStorage', {
35
36
  bucketName: 'my-mwaa-dag-storage',
36
- removalPolicy: cdk.RemovalPolicy.DESTROY,
37
+ dagsConfig: {
38
+ localPath: path.join(__dirname, 'dags'),
39
+ s3Path: 'dags/',
40
+ },
41
+ // additional configuration options...
37
42
  });
38
43
 
39
44
  new mwaa.Environment(stack, 'MyMwaaEnvironment', {
40
- environmentName: 'my-mwaa-environment',
45
+ name: 'my-mwaa-environment',
41
46
  dagStorage,
42
47
  airflowVersion: '2.10.3',
43
48
  sizing: mwaa.Sizing.mw1Micro(),
@@ -62,17 +67,18 @@ const stack = new cdk.Stack(app, 'MwaaStack');
62
67
 
63
68
  const dagStorage = new mwaa.DagStorage(stack, 'MyMwaaDagStorage', {
64
69
  bucketName: 'my-mwaa-dag-storage',
65
- removalPolicy: cdk.RemovalPolicy.DESTROY,
70
+ // additional configuration options...
66
71
  });
67
72
 
68
73
  const environment = new mwaa.Environment(stack, 'MyMwaaEnvironment', {
69
- environmentName: 'my-mwaa-environment',
74
+ name: 'my-mwaa-environment',
70
75
  dagStorage,
71
76
  airflowVersion: '2.10.3',
72
77
  sizing: mwaa.Sizing.mw1Micro(),
73
78
  // additional configuration options...
74
79
  });
75
80
 
81
+ // Enabling Secrets Backend
76
82
  environment.enableSecretsBackend();
77
83
 
78
84
  app.synth();
@@ -119,7 +125,6 @@ import aws_cdk.aws_ec2 as _aws_cdk_aws_ec2_ceddda9d
119
125
  import aws_cdk.aws_iam as _aws_cdk_aws_iam_ceddda9d
120
126
  import aws_cdk.aws_kms as _aws_cdk_aws_kms_ceddda9d
121
127
  import aws_cdk.aws_s3 as _aws_cdk_aws_s3_ceddda9d
122
- import aws_cdk.aws_s3_deployment as _aws_cdk_aws_s3_deployment_ceddda9d
123
128
  import constructs as _constructs_77d1e7e8
124
129
 
125
130
 
@@ -128,7 +133,7 @@ class DagStorage(
128
133
  metaclass=jsii.JSIIMeta,
129
134
  jsii_type="cdk-mwaa.DagStorage",
130
135
  ):
131
- '''Represents a storage location for MWAA DAGs and dependencies in an S3 bucket.'''
136
+ '''Represents an S3 storage solution for MWAA DAGs and dependencies.'''
132
137
 
133
138
  def __init__(
134
139
  self,
@@ -136,24 +141,22 @@ class DagStorage(
136
141
  id: builtins.str,
137
142
  *,
138
143
  bucket_name: typing.Optional[builtins.str] = None,
139
- dag_s3_path: typing.Optional[builtins.str] = None,
140
- deploy_options: typing.Optional[typing.Union["DagStorageDeployOptions", typing.Dict[builtins.str, typing.Any]]] = None,
144
+ dags_config: typing.Optional[typing.Union["DagStorageConfigOptions", typing.Dict[builtins.str, typing.Any]]] = None,
141
145
  noncurrent_version_expiration: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
142
- plugins_config: typing.Optional[typing.Union["DagStorageConfigOptions", typing.Dict[builtins.str, typing.Any]]] = None,
146
+ plugins_config: typing.Optional[typing.Union["DagStorageConfigOptionsWithS3ObjectVersion", typing.Dict[builtins.str, typing.Any]]] = None,
143
147
  removal_policy: typing.Optional[_aws_cdk_ceddda9d.RemovalPolicy] = None,
144
- requirements_config: typing.Optional[typing.Union["DagStorageConfigOptions", typing.Dict[builtins.str, typing.Any]]] = None,
145
- startup_script_config: typing.Optional[typing.Union["DagStorageConfigOptions", typing.Dict[builtins.str, typing.Any]]] = None,
148
+ requirements_config: typing.Optional[typing.Union["DagStorageConfigOptionsWithS3ObjectVersion", typing.Dict[builtins.str, typing.Any]]] = None,
149
+ startup_script_config: typing.Optional[typing.Union["DagStorageConfigOptionsWithS3ObjectVersion", typing.Dict[builtins.str, typing.Any]]] = None,
146
150
  versioned: typing.Optional[builtins.bool] = None,
147
151
  ) -> None:
148
152
  '''
149
153
  :param scope: -
150
154
  :param id: -
151
- :param bucket_name: Optional custom bucket name.
152
- :param dag_s3_path: Path for storing DAG files.
153
- :param deploy_options: Options for deploying files into the bucket.
154
- :param noncurrent_version_expiration: Lifecycle rule for expiring non-current versions.
155
+ :param bucket_name: Custom bucket name (optional).
156
+ :param dags_config: Configuration for DAG storage.
157
+ :param noncurrent_version_expiration: Lifecycle rule for expiring non-current object versions.
155
158
  :param plugins_config: Configuration for plugins storage.
156
- :param removal_policy: Policy for bucket removal.
159
+ :param removal_policy: Bucket removal policy.
157
160
  :param requirements_config: Configuration for requirements storage.
158
161
  :param startup_script_config: Configuration for startup script storage.
159
162
  :param versioned: Enable versioning for the bucket.
@@ -164,8 +167,7 @@ class DagStorage(
164
167
  check_type(argname="argument id", value=id, expected_type=type_hints["id"])
165
168
  props = DagStorageProps(
166
169
  bucket_name=bucket_name,
167
- dag_s3_path=dag_s3_path,
168
- deploy_options=deploy_options,
170
+ dags_config=dags_config,
169
171
  noncurrent_version_expiration=noncurrent_version_expiration,
170
172
  plugins_config=plugins_config,
171
173
  removal_policy=removal_policy,
@@ -190,47 +192,138 @@ class DagStorage(
190
192
 
191
193
  @builtins.property
192
194
  @jsii.member(jsii_name="pluginsConfig")
193
- def plugins_config(self) -> typing.Optional["DagStorageConfigOptions"]:
195
+ def plugins_config(
196
+ self,
197
+ ) -> typing.Optional["DagStorageConfigOptionsWithS3ObjectVersion"]:
194
198
  '''Plugin storage configuration.'''
195
- return typing.cast(typing.Optional["DagStorageConfigOptions"], jsii.get(self, "pluginsConfig"))
199
+ return typing.cast(typing.Optional["DagStorageConfigOptionsWithS3ObjectVersion"], jsii.get(self, "pluginsConfig"))
196
200
 
197
201
  @builtins.property
198
202
  @jsii.member(jsii_name="requirementsConfig")
199
- def requirements_config(self) -> typing.Optional["DagStorageConfigOptions"]:
203
+ def requirements_config(
204
+ self,
205
+ ) -> typing.Optional["DagStorageConfigOptionsWithS3ObjectVersion"]:
200
206
  '''Requirements storage configuration.'''
201
- return typing.cast(typing.Optional["DagStorageConfigOptions"], jsii.get(self, "requirementsConfig"))
207
+ return typing.cast(typing.Optional["DagStorageConfigOptionsWithS3ObjectVersion"], jsii.get(self, "requirementsConfig"))
202
208
 
203
209
  @builtins.property
204
210
  @jsii.member(jsii_name="startupScriptConfig")
205
- def startup_script_config(self) -> typing.Optional["DagStorageConfigOptions"]:
211
+ def startup_script_config(
212
+ self,
213
+ ) -> typing.Optional["DagStorageConfigOptionsWithS3ObjectVersion"]:
206
214
  '''Startup script storage configuration.'''
207
- return typing.cast(typing.Optional["DagStorageConfigOptions"], jsii.get(self, "startupScriptConfig"))
215
+ return typing.cast(typing.Optional["DagStorageConfigOptionsWithS3ObjectVersion"], jsii.get(self, "startupScriptConfig"))
208
216
 
209
217
 
210
218
  @jsii.data_type(
211
219
  jsii_type="cdk-mwaa.DagStorageConfigOptions",
212
220
  jsii_struct_bases=[],
213
- name_mapping={"s3_path": "s3Path", "s3_object_version": "s3ObjectVersion"},
221
+ name_mapping={
222
+ "s3_path": "s3Path",
223
+ "deploy_options": "deployOptions",
224
+ "local_path": "localPath",
225
+ },
214
226
  )
215
227
  class DagStorageConfigOptions:
216
228
  def __init__(
217
229
  self,
218
230
  *,
219
231
  s3_path: builtins.str,
220
- s3_object_version: typing.Optional[builtins.str] = None,
232
+ deploy_options: typing.Optional[typing.Union["DagStorageDeployOptions", typing.Dict[builtins.str, typing.Any]]] = None,
233
+ local_path: typing.Optional[builtins.str] = None,
221
234
  ) -> None:
222
- '''Configuration options for S3 path storage.
235
+ '''Configuration options for DAG storage.
223
236
 
224
237
  :param s3_path: The S3 path where the resource is stored.
225
- :param s3_object_version: Optional object version for versioned buckets.
238
+ :param deploy_options: Deployment options for DAG storage.
239
+ :param local_path: Optional local path for the resource.
226
240
  '''
241
+ if isinstance(deploy_options, dict):
242
+ deploy_options = DagStorageDeployOptions(**deploy_options)
227
243
  if __debug__:
228
244
  type_hints = typing.get_type_hints(_typecheckingstub__85a9b5242a26a2093aa8052dd8b86bea06801d5a767c2e5f908776c3f849eb63)
229
245
  check_type(argname="argument s3_path", value=s3_path, expected_type=type_hints["s3_path"])
246
+ check_type(argname="argument deploy_options", value=deploy_options, expected_type=type_hints["deploy_options"])
247
+ check_type(argname="argument local_path", value=local_path, expected_type=type_hints["local_path"])
248
+ self._values: typing.Dict[builtins.str, typing.Any] = {
249
+ "s3_path": s3_path,
250
+ }
251
+ if deploy_options is not None:
252
+ self._values["deploy_options"] = deploy_options
253
+ if local_path is not None:
254
+ self._values["local_path"] = local_path
255
+
256
+ @builtins.property
257
+ def s3_path(self) -> builtins.str:
258
+ '''The S3 path where the resource is stored.'''
259
+ result = self._values.get("s3_path")
260
+ assert result is not None, "Required property 's3_path' is missing"
261
+ return typing.cast(builtins.str, result)
262
+
263
+ @builtins.property
264
+ def deploy_options(self) -> typing.Optional["DagStorageDeployOptions"]:
265
+ '''Deployment options for DAG storage.'''
266
+ result = self._values.get("deploy_options")
267
+ return typing.cast(typing.Optional["DagStorageDeployOptions"], result)
268
+
269
+ @builtins.property
270
+ def local_path(self) -> typing.Optional[builtins.str]:
271
+ '''Optional local path for the resource.'''
272
+ result = self._values.get("local_path")
273
+ return typing.cast(typing.Optional[builtins.str], result)
274
+
275
+ def __eq__(self, rhs: typing.Any) -> builtins.bool:
276
+ return isinstance(rhs, self.__class__) and rhs._values == self._values
277
+
278
+ def __ne__(self, rhs: typing.Any) -> builtins.bool:
279
+ return not (rhs == self)
280
+
281
+ def __repr__(self) -> str:
282
+ return "DagStorageConfigOptions(%s)" % ", ".join(
283
+ k + "=" + repr(v) for k, v in self._values.items()
284
+ )
285
+
286
+
287
+ @jsii.data_type(
288
+ jsii_type="cdk-mwaa.DagStorageConfigOptionsWithS3ObjectVersion",
289
+ jsii_struct_bases=[DagStorageConfigOptions],
290
+ name_mapping={
291
+ "s3_path": "s3Path",
292
+ "deploy_options": "deployOptions",
293
+ "local_path": "localPath",
294
+ "s3_object_version": "s3ObjectVersion",
295
+ },
296
+ )
297
+ class DagStorageConfigOptionsWithS3ObjectVersion(DagStorageConfigOptions):
298
+ def __init__(
299
+ self,
300
+ *,
301
+ s3_path: builtins.str,
302
+ deploy_options: typing.Optional[typing.Union["DagStorageDeployOptions", typing.Dict[builtins.str, typing.Any]]] = None,
303
+ local_path: typing.Optional[builtins.str] = None,
304
+ s3_object_version: typing.Optional[builtins.str] = None,
305
+ ) -> None:
306
+ '''
307
+ :param s3_path: The S3 path where the resource is stored.
308
+ :param deploy_options: Deployment options for DAG storage.
309
+ :param local_path: Optional local path for the resource.
310
+ :param s3_object_version: S3 object version identifier.
311
+ '''
312
+ if isinstance(deploy_options, dict):
313
+ deploy_options = DagStorageDeployOptions(**deploy_options)
314
+ if __debug__:
315
+ type_hints = typing.get_type_hints(_typecheckingstub__1fd77af7d832e6c1f66f71849ff7971c010e8282b5b3a43d573c7892c43539cf)
316
+ check_type(argname="argument s3_path", value=s3_path, expected_type=type_hints["s3_path"])
317
+ check_type(argname="argument deploy_options", value=deploy_options, expected_type=type_hints["deploy_options"])
318
+ check_type(argname="argument local_path", value=local_path, expected_type=type_hints["local_path"])
230
319
  check_type(argname="argument s3_object_version", value=s3_object_version, expected_type=type_hints["s3_object_version"])
231
320
  self._values: typing.Dict[builtins.str, typing.Any] = {
232
321
  "s3_path": s3_path,
233
322
  }
323
+ if deploy_options is not None:
324
+ self._values["deploy_options"] = deploy_options
325
+ if local_path is not None:
326
+ self._values["local_path"] = local_path
234
327
  if s3_object_version is not None:
235
328
  self._values["s3_object_version"] = s3_object_version
236
329
 
@@ -241,9 +334,21 @@ class DagStorageConfigOptions:
241
334
  assert result is not None, "Required property 's3_path' is missing"
242
335
  return typing.cast(builtins.str, result)
243
336
 
337
+ @builtins.property
338
+ def deploy_options(self) -> typing.Optional["DagStorageDeployOptions"]:
339
+ '''Deployment options for DAG storage.'''
340
+ result = self._values.get("deploy_options")
341
+ return typing.cast(typing.Optional["DagStorageDeployOptions"], result)
342
+
343
+ @builtins.property
344
+ def local_path(self) -> typing.Optional[builtins.str]:
345
+ '''Optional local path for the resource.'''
346
+ result = self._values.get("local_path")
347
+ return typing.cast(typing.Optional[builtins.str], result)
348
+
244
349
  @builtins.property
245
350
  def s3_object_version(self) -> typing.Optional[builtins.str]:
246
- '''Optional object version for versioned buckets.'''
351
+ '''S3 object version identifier.'''
247
352
  result = self._values.get("s3_object_version")
248
353
  return typing.cast(typing.Optional[builtins.str], result)
249
354
 
@@ -254,7 +359,7 @@ class DagStorageConfigOptions:
254
359
  return not (rhs == self)
255
360
 
256
361
  def __repr__(self) -> str:
257
- return "DagStorageConfigOptions(%s)" % ", ".join(
362
+ return "DagStorageConfigOptionsWithS3ObjectVersion(%s)" % ", ".join(
258
363
  k + "=" + repr(v) for k, v in self._values.items()
259
364
  )
260
365
 
@@ -263,58 +368,56 @@ class DagStorageConfigOptions:
263
368
  jsii_type="cdk-mwaa.DagStorageDeployOptions",
264
369
  jsii_struct_bases=[],
265
370
  name_mapping={
371
+ "exclude": "exclude",
266
372
  "prune": "prune",
267
373
  "retain_on_delete": "retainOnDelete",
268
- "sources": "sources",
269
374
  },
270
375
  )
271
376
  class DagStorageDeployOptions:
272
377
  def __init__(
273
378
  self,
274
379
  *,
380
+ exclude: typing.Optional[typing.Sequence[builtins.str]] = None,
275
381
  prune: typing.Optional[builtins.bool] = None,
276
382
  retain_on_delete: typing.Optional[builtins.bool] = None,
277
- sources: typing.Optional[typing.Sequence[_aws_cdk_aws_s3_deployment_ceddda9d.ISource]] = None,
278
383
  ) -> None:
279
384
  '''Options for deploying files to the DAG storage bucket.
280
385
 
281
- :param prune: Whether to prune old versions of deployed files.
282
- :param retain_on_delete: Whether to retain files on deletion of the stack.
283
- :param sources: Sources to deploy into the bucket.
386
+ :param exclude: Patterns to exclude from deployment.
387
+ :param prune: Whether to remove outdated file versions.
388
+ :param retain_on_delete: Whether to retain files upon stack deletion.
284
389
  '''
285
390
  if __debug__:
286
391
  type_hints = typing.get_type_hints(_typecheckingstub__c4eb47db99cbba877092424afc09de8c308a38be2c61e698dd0c28933b9c3b42)
392
+ check_type(argname="argument exclude", value=exclude, expected_type=type_hints["exclude"])
287
393
  check_type(argname="argument prune", value=prune, expected_type=type_hints["prune"])
288
394
  check_type(argname="argument retain_on_delete", value=retain_on_delete, expected_type=type_hints["retain_on_delete"])
289
- check_type(argname="argument sources", value=sources, expected_type=type_hints["sources"])
290
395
  self._values: typing.Dict[builtins.str, typing.Any] = {}
396
+ if exclude is not None:
397
+ self._values["exclude"] = exclude
291
398
  if prune is not None:
292
399
  self._values["prune"] = prune
293
400
  if retain_on_delete is not None:
294
401
  self._values["retain_on_delete"] = retain_on_delete
295
- if sources is not None:
296
- self._values["sources"] = sources
402
+
403
+ @builtins.property
404
+ def exclude(self) -> typing.Optional[typing.List[builtins.str]]:
405
+ '''Patterns to exclude from deployment.'''
406
+ result = self._values.get("exclude")
407
+ return typing.cast(typing.Optional[typing.List[builtins.str]], result)
297
408
 
298
409
  @builtins.property
299
410
  def prune(self) -> typing.Optional[builtins.bool]:
300
- '''Whether to prune old versions of deployed files.'''
411
+ '''Whether to remove outdated file versions.'''
301
412
  result = self._values.get("prune")
302
413
  return typing.cast(typing.Optional[builtins.bool], result)
303
414
 
304
415
  @builtins.property
305
416
  def retain_on_delete(self) -> typing.Optional[builtins.bool]:
306
- '''Whether to retain files on deletion of the stack.'''
417
+ '''Whether to retain files upon stack deletion.'''
307
418
  result = self._values.get("retain_on_delete")
308
419
  return typing.cast(typing.Optional[builtins.bool], result)
309
420
 
310
- @builtins.property
311
- def sources(
312
- self,
313
- ) -> typing.Optional[typing.List[_aws_cdk_aws_s3_deployment_ceddda9d.ISource]]:
314
- '''Sources to deploy into the bucket.'''
315
- result = self._values.get("sources")
316
- return typing.cast(typing.Optional[typing.List[_aws_cdk_aws_s3_deployment_ceddda9d.ISource]], result)
317
-
318
421
  def __eq__(self, rhs: typing.Any) -> builtins.bool:
319
422
  return isinstance(rhs, self.__class__) and rhs._values == self._values
320
423
 
@@ -332,8 +435,7 @@ class DagStorageDeployOptions:
332
435
  jsii_struct_bases=[],
333
436
  name_mapping={
334
437
  "bucket_name": "bucketName",
335
- "dag_s3_path": "dagS3Path",
336
- "deploy_options": "deployOptions",
438
+ "dags_config": "dagsConfig",
337
439
  "noncurrent_version_expiration": "noncurrentVersionExpiration",
338
440
  "plugins_config": "pluginsConfig",
339
441
  "removal_policy": "removalPolicy",
@@ -347,40 +449,37 @@ class DagStorageProps:
347
449
  self,
348
450
  *,
349
451
  bucket_name: typing.Optional[builtins.str] = None,
350
- dag_s3_path: typing.Optional[builtins.str] = None,
351
- deploy_options: typing.Optional[typing.Union[DagStorageDeployOptions, typing.Dict[builtins.str, typing.Any]]] = None,
452
+ dags_config: typing.Optional[typing.Union[DagStorageConfigOptions, typing.Dict[builtins.str, typing.Any]]] = None,
352
453
  noncurrent_version_expiration: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
353
- plugins_config: typing.Optional[typing.Union[DagStorageConfigOptions, typing.Dict[builtins.str, typing.Any]]] = None,
454
+ plugins_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
354
455
  removal_policy: typing.Optional[_aws_cdk_ceddda9d.RemovalPolicy] = None,
355
- requirements_config: typing.Optional[typing.Union[DagStorageConfigOptions, typing.Dict[builtins.str, typing.Any]]] = None,
356
- startup_script_config: typing.Optional[typing.Union[DagStorageConfigOptions, typing.Dict[builtins.str, typing.Any]]] = None,
456
+ requirements_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
457
+ startup_script_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
357
458
  versioned: typing.Optional[builtins.bool] = None,
358
459
  ) -> None:
359
460
  '''Properties for configuring the DAG storage bucket.
360
461
 
361
- :param bucket_name: Optional custom bucket name.
362
- :param dag_s3_path: Path for storing DAG files.
363
- :param deploy_options: Options for deploying files into the bucket.
364
- :param noncurrent_version_expiration: Lifecycle rule for expiring non-current versions.
462
+ :param bucket_name: Custom bucket name (optional).
463
+ :param dags_config: Configuration for DAG storage.
464
+ :param noncurrent_version_expiration: Lifecycle rule for expiring non-current object versions.
365
465
  :param plugins_config: Configuration for plugins storage.
366
- :param removal_policy: Policy for bucket removal.
466
+ :param removal_policy: Bucket removal policy.
367
467
  :param requirements_config: Configuration for requirements storage.
368
468
  :param startup_script_config: Configuration for startup script storage.
369
469
  :param versioned: Enable versioning for the bucket.
370
470
  '''
371
- if isinstance(deploy_options, dict):
372
- deploy_options = DagStorageDeployOptions(**deploy_options)
471
+ if isinstance(dags_config, dict):
472
+ dags_config = DagStorageConfigOptions(**dags_config)
373
473
  if isinstance(plugins_config, dict):
374
- plugins_config = DagStorageConfigOptions(**plugins_config)
474
+ plugins_config = DagStorageConfigOptionsWithS3ObjectVersion(**plugins_config)
375
475
  if isinstance(requirements_config, dict):
376
- requirements_config = DagStorageConfigOptions(**requirements_config)
476
+ requirements_config = DagStorageConfigOptionsWithS3ObjectVersion(**requirements_config)
377
477
  if isinstance(startup_script_config, dict):
378
- startup_script_config = DagStorageConfigOptions(**startup_script_config)
478
+ startup_script_config = DagStorageConfigOptionsWithS3ObjectVersion(**startup_script_config)
379
479
  if __debug__:
380
480
  type_hints = typing.get_type_hints(_typecheckingstub__6a4bace9647a9566f3af4198e17ef015306e92a6d5f673b579ba6fdfcb5231da)
381
481
  check_type(argname="argument bucket_name", value=bucket_name, expected_type=type_hints["bucket_name"])
382
- check_type(argname="argument dag_s3_path", value=dag_s3_path, expected_type=type_hints["dag_s3_path"])
383
- check_type(argname="argument deploy_options", value=deploy_options, expected_type=type_hints["deploy_options"])
482
+ check_type(argname="argument dags_config", value=dags_config, expected_type=type_hints["dags_config"])
384
483
  check_type(argname="argument noncurrent_version_expiration", value=noncurrent_version_expiration, expected_type=type_hints["noncurrent_version_expiration"])
385
484
  check_type(argname="argument plugins_config", value=plugins_config, expected_type=type_hints["plugins_config"])
386
485
  check_type(argname="argument removal_policy", value=removal_policy, expected_type=type_hints["removal_policy"])
@@ -390,10 +489,8 @@ class DagStorageProps:
390
489
  self._values: typing.Dict[builtins.str, typing.Any] = {}
391
490
  if bucket_name is not None:
392
491
  self._values["bucket_name"] = bucket_name
393
- if dag_s3_path is not None:
394
- self._values["dag_s3_path"] = dag_s3_path
395
- if deploy_options is not None:
396
- self._values["deploy_options"] = deploy_options
492
+ if dags_config is not None:
493
+ self._values["dags_config"] = dags_config
397
494
  if noncurrent_version_expiration is not None:
398
495
  self._values["noncurrent_version_expiration"] = noncurrent_version_expiration
399
496
  if plugins_config is not None:
@@ -409,53 +506,53 @@ class DagStorageProps:
409
506
 
410
507
  @builtins.property
411
508
  def bucket_name(self) -> typing.Optional[builtins.str]:
412
- '''Optional custom bucket name.'''
509
+ '''Custom bucket name (optional).'''
413
510
  result = self._values.get("bucket_name")
414
511
  return typing.cast(typing.Optional[builtins.str], result)
415
512
 
416
513
  @builtins.property
417
- def dag_s3_path(self) -> typing.Optional[builtins.str]:
418
- '''Path for storing DAG files.'''
419
- result = self._values.get("dag_s3_path")
420
- return typing.cast(typing.Optional[builtins.str], result)
421
-
422
- @builtins.property
423
- def deploy_options(self) -> typing.Optional[DagStorageDeployOptions]:
424
- '''Options for deploying files into the bucket.'''
425
- result = self._values.get("deploy_options")
426
- return typing.cast(typing.Optional[DagStorageDeployOptions], result)
514
+ def dags_config(self) -> typing.Optional[DagStorageConfigOptions]:
515
+ '''Configuration for DAG storage.'''
516
+ result = self._values.get("dags_config")
517
+ return typing.cast(typing.Optional[DagStorageConfigOptions], result)
427
518
 
428
519
  @builtins.property
429
520
  def noncurrent_version_expiration(
430
521
  self,
431
522
  ) -> typing.Optional[_aws_cdk_ceddda9d.Duration]:
432
- '''Lifecycle rule for expiring non-current versions.'''
523
+ '''Lifecycle rule for expiring non-current object versions.'''
433
524
  result = self._values.get("noncurrent_version_expiration")
434
525
  return typing.cast(typing.Optional[_aws_cdk_ceddda9d.Duration], result)
435
526
 
436
527
  @builtins.property
437
- def plugins_config(self) -> typing.Optional[DagStorageConfigOptions]:
528
+ def plugins_config(
529
+ self,
530
+ ) -> typing.Optional[DagStorageConfigOptionsWithS3ObjectVersion]:
438
531
  '''Configuration for plugins storage.'''
439
532
  result = self._values.get("plugins_config")
440
- return typing.cast(typing.Optional[DagStorageConfigOptions], result)
533
+ return typing.cast(typing.Optional[DagStorageConfigOptionsWithS3ObjectVersion], result)
441
534
 
442
535
  @builtins.property
443
536
  def removal_policy(self) -> typing.Optional[_aws_cdk_ceddda9d.RemovalPolicy]:
444
- '''Policy for bucket removal.'''
537
+ '''Bucket removal policy.'''
445
538
  result = self._values.get("removal_policy")
446
539
  return typing.cast(typing.Optional[_aws_cdk_ceddda9d.RemovalPolicy], result)
447
540
 
448
541
  @builtins.property
449
- def requirements_config(self) -> typing.Optional[DagStorageConfigOptions]:
542
+ def requirements_config(
543
+ self,
544
+ ) -> typing.Optional[DagStorageConfigOptionsWithS3ObjectVersion]:
450
545
  '''Configuration for requirements storage.'''
451
546
  result = self._values.get("requirements_config")
452
- return typing.cast(typing.Optional[DagStorageConfigOptions], result)
547
+ return typing.cast(typing.Optional[DagStorageConfigOptionsWithS3ObjectVersion], result)
453
548
 
454
549
  @builtins.property
455
- def startup_script_config(self) -> typing.Optional[DagStorageConfigOptions]:
550
+ def startup_script_config(
551
+ self,
552
+ ) -> typing.Optional[DagStorageConfigOptionsWithS3ObjectVersion]:
456
553
  '''Configuration for startup script storage.'''
457
554
  result = self._values.get("startup_script_config")
458
- return typing.cast(typing.Optional[DagStorageConfigOptions], result)
555
+ return typing.cast(typing.Optional[DagStorageConfigOptionsWithS3ObjectVersion], result)
459
556
 
460
557
  @builtins.property
461
558
  def versioned(self) -> typing.Optional[builtins.bool]:
@@ -547,7 +644,7 @@ class Environment(
547
644
  *,
548
645
  airflow_version: builtins.str,
549
646
  dag_storage: DagStorage,
550
- environment_name: builtins.str,
647
+ name: builtins.str,
551
648
  sizing: "Sizing",
552
649
  vpc: _aws_cdk_aws_ec2_ceddda9d.IVpc,
553
650
  airflow_configuration_options: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
@@ -565,7 +662,7 @@ class Environment(
565
662
  :param id: - The unique ID of the construct.
566
663
  :param airflow_version:
567
664
  :param dag_storage:
568
- :param environment_name:
665
+ :param name:
569
666
  :param sizing:
570
667
  :param vpc:
571
668
  :param airflow_configuration_options:
@@ -584,7 +681,7 @@ class Environment(
584
681
  props = EnvironmentProps(
585
682
  airflow_version=airflow_version,
586
683
  dag_storage=dag_storage,
587
- environment_name=environment_name,
684
+ name=name,
588
685
  sizing=sizing,
589
686
  vpc=vpc,
590
687
  airflow_configuration_options=airflow_configuration_options,
@@ -740,7 +837,7 @@ class EnvironmentClass(enum.Enum):
740
837
  name_mapping={
741
838
  "airflow_version": "airflowVersion",
742
839
  "dag_storage": "dagStorage",
743
- "environment_name": "environmentName",
840
+ "name": "name",
744
841
  "sizing": "sizing",
745
842
  "vpc": "vpc",
746
843
  "airflow_configuration_options": "airflowConfigurationOptions",
@@ -759,7 +856,7 @@ class EnvironmentProps:
759
856
  *,
760
857
  airflow_version: builtins.str,
761
858
  dag_storage: DagStorage,
762
- environment_name: builtins.str,
859
+ name: builtins.str,
763
860
  sizing: "Sizing",
764
861
  vpc: _aws_cdk_aws_ec2_ceddda9d.IVpc,
765
862
  airflow_configuration_options: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
@@ -775,7 +872,7 @@ class EnvironmentProps:
775
872
 
776
873
  :param airflow_version:
777
874
  :param dag_storage:
778
- :param environment_name:
875
+ :param name:
779
876
  :param sizing:
780
877
  :param vpc:
781
878
  :param airflow_configuration_options:
@@ -793,7 +890,7 @@ class EnvironmentProps:
793
890
  type_hints = typing.get_type_hints(_typecheckingstub__d58cfc6f1183850b5b51999d54a17bf62c6f7b5c3c75133b721818d02e12a9b8)
794
891
  check_type(argname="argument airflow_version", value=airflow_version, expected_type=type_hints["airflow_version"])
795
892
  check_type(argname="argument dag_storage", value=dag_storage, expected_type=type_hints["dag_storage"])
796
- check_type(argname="argument environment_name", value=environment_name, expected_type=type_hints["environment_name"])
893
+ check_type(argname="argument name", value=name, expected_type=type_hints["name"])
797
894
  check_type(argname="argument sizing", value=sizing, expected_type=type_hints["sizing"])
798
895
  check_type(argname="argument vpc", value=vpc, expected_type=type_hints["vpc"])
799
896
  check_type(argname="argument airflow_configuration_options", value=airflow_configuration_options, expected_type=type_hints["airflow_configuration_options"])
@@ -807,7 +904,7 @@ class EnvironmentProps:
807
904
  self._values: typing.Dict[builtins.str, typing.Any] = {
808
905
  "airflow_version": airflow_version,
809
906
  "dag_storage": dag_storage,
810
- "environment_name": environment_name,
907
+ "name": name,
811
908
  "sizing": sizing,
812
909
  "vpc": vpc,
813
910
  }
@@ -841,9 +938,9 @@ class EnvironmentProps:
841
938
  return typing.cast(DagStorage, result)
842
939
 
843
940
  @builtins.property
844
- def environment_name(self) -> builtins.str:
845
- result = self._values.get("environment_name")
846
- assert result is not None, "Required property 'environment_name' is missing"
941
+ def name(self) -> builtins.str:
942
+ result = self._values.get("name")
943
+ assert result is not None, "Required property 'name' is missing"
847
944
  return typing.cast(builtins.str, result)
848
945
 
849
946
  @builtins.property
@@ -1079,9 +1176,12 @@ class LoggingConfigurationProperty:
1079
1176
  "environment_name": "environmentName",
1080
1177
  "airflow_configuration_options": "airflowConfigurationOptions",
1081
1178
  "bucket_name": "bucketName",
1082
- "deploy_options": "deployOptions",
1179
+ "dags_config": "dagsConfig",
1180
+ "plugins_config": "pluginsConfig",
1083
1181
  "removal_policy": "removalPolicy",
1182
+ "requirements_config": "requirementsConfig",
1084
1183
  "sizing": "sizing",
1184
+ "startup_script_config": "startupScriptConfig",
1085
1185
  "vpc": "vpc",
1086
1186
  },
1087
1187
  )
@@ -1093,9 +1193,12 @@ class MWAAProps:
1093
1193
  environment_name: builtins.str,
1094
1194
  airflow_configuration_options: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
1095
1195
  bucket_name: typing.Optional[builtins.str] = None,
1096
- deploy_options: typing.Optional[typing.Union[DagStorageDeployOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1196
+ dags_config: typing.Optional[typing.Union[DagStorageConfigOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1197
+ plugins_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1097
1198
  removal_policy: typing.Optional[_aws_cdk_ceddda9d.RemovalPolicy] = None,
1199
+ requirements_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1098
1200
  sizing: typing.Optional["Sizing"] = None,
1201
+ startup_script_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1099
1202
  vpc: typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc] = None,
1100
1203
  ) -> None:
1101
1204
  '''Interface defining the properties for configuring MWAA (Managed Airflow).
@@ -1104,22 +1207,34 @@ class MWAAProps:
1104
1207
  :param environment_name: The name of the Airflow environment.
1105
1208
  :param airflow_configuration_options: Airflow configuration options as key-value pairs. These configuration options are passed to the Airflow environment.
1106
1209
  :param bucket_name: The name of the S3 bucket used for storing DAGs. If not provided, a default bucket is created.
1107
- :param deploy_options: Optional DAG storage deployment options. Configures how the DAGs are deployed to the S3 bucket.
1210
+ :param dags_config: Configuration for DAG storage.
1211
+ :param plugins_config: Configuration for plugins storage.
1108
1212
  :param removal_policy: The removal policy for the MWAA resources. Determines what happens to the resources when they are deleted. Defaults to 'RETAIN' if not specified.
1213
+ :param requirements_config: Configuration for requirements storage.
1109
1214
  :param sizing: Optional sizing configuration for the MWAA environment. Defines the compute resources.
1215
+ :param startup_script_config: Configuration for startup script storage.
1110
1216
  :param vpc: The VPC in which to deploy the MWAA environment. If not provided, a default VPC will be created.
1111
1217
  '''
1112
- if isinstance(deploy_options, dict):
1113
- deploy_options = DagStorageDeployOptions(**deploy_options)
1218
+ if isinstance(dags_config, dict):
1219
+ dags_config = DagStorageConfigOptions(**dags_config)
1220
+ if isinstance(plugins_config, dict):
1221
+ plugins_config = DagStorageConfigOptionsWithS3ObjectVersion(**plugins_config)
1222
+ if isinstance(requirements_config, dict):
1223
+ requirements_config = DagStorageConfigOptionsWithS3ObjectVersion(**requirements_config)
1224
+ if isinstance(startup_script_config, dict):
1225
+ startup_script_config = DagStorageConfigOptionsWithS3ObjectVersion(**startup_script_config)
1114
1226
  if __debug__:
1115
1227
  type_hints = typing.get_type_hints(_typecheckingstub__e73d818937427f32bb22179ff7d13eb6aa0201131959780924f6ec21b94dd128)
1116
1228
  check_type(argname="argument airflow_version", value=airflow_version, expected_type=type_hints["airflow_version"])
1117
1229
  check_type(argname="argument environment_name", value=environment_name, expected_type=type_hints["environment_name"])
1118
1230
  check_type(argname="argument airflow_configuration_options", value=airflow_configuration_options, expected_type=type_hints["airflow_configuration_options"])
1119
1231
  check_type(argname="argument bucket_name", value=bucket_name, expected_type=type_hints["bucket_name"])
1120
- check_type(argname="argument deploy_options", value=deploy_options, expected_type=type_hints["deploy_options"])
1232
+ check_type(argname="argument dags_config", value=dags_config, expected_type=type_hints["dags_config"])
1233
+ check_type(argname="argument plugins_config", value=plugins_config, expected_type=type_hints["plugins_config"])
1121
1234
  check_type(argname="argument removal_policy", value=removal_policy, expected_type=type_hints["removal_policy"])
1235
+ check_type(argname="argument requirements_config", value=requirements_config, expected_type=type_hints["requirements_config"])
1122
1236
  check_type(argname="argument sizing", value=sizing, expected_type=type_hints["sizing"])
1237
+ check_type(argname="argument startup_script_config", value=startup_script_config, expected_type=type_hints["startup_script_config"])
1123
1238
  check_type(argname="argument vpc", value=vpc, expected_type=type_hints["vpc"])
1124
1239
  self._values: typing.Dict[builtins.str, typing.Any] = {
1125
1240
  "airflow_version": airflow_version,
@@ -1129,12 +1244,18 @@ class MWAAProps:
1129
1244
  self._values["airflow_configuration_options"] = airflow_configuration_options
1130
1245
  if bucket_name is not None:
1131
1246
  self._values["bucket_name"] = bucket_name
1132
- if deploy_options is not None:
1133
- self._values["deploy_options"] = deploy_options
1247
+ if dags_config is not None:
1248
+ self._values["dags_config"] = dags_config
1249
+ if plugins_config is not None:
1250
+ self._values["plugins_config"] = plugins_config
1134
1251
  if removal_policy is not None:
1135
1252
  self._values["removal_policy"] = removal_policy
1253
+ if requirements_config is not None:
1254
+ self._values["requirements_config"] = requirements_config
1136
1255
  if sizing is not None:
1137
1256
  self._values["sizing"] = sizing
1257
+ if startup_script_config is not None:
1258
+ self._values["startup_script_config"] = startup_script_config
1138
1259
  if vpc is not None:
1139
1260
  self._values["vpc"] = vpc
1140
1261
 
@@ -1173,13 +1294,18 @@ class MWAAProps:
1173
1294
  return typing.cast(typing.Optional[builtins.str], result)
1174
1295
 
1175
1296
  @builtins.property
1176
- def deploy_options(self) -> typing.Optional[DagStorageDeployOptions]:
1177
- '''Optional DAG storage deployment options.
1297
+ def dags_config(self) -> typing.Optional[DagStorageConfigOptions]:
1298
+ '''Configuration for DAG storage.'''
1299
+ result = self._values.get("dags_config")
1300
+ return typing.cast(typing.Optional[DagStorageConfigOptions], result)
1178
1301
 
1179
- Configures how the DAGs are deployed to the S3 bucket.
1180
- '''
1181
- result = self._values.get("deploy_options")
1182
- return typing.cast(typing.Optional[DagStorageDeployOptions], result)
1302
+ @builtins.property
1303
+ def plugins_config(
1304
+ self,
1305
+ ) -> typing.Optional[DagStorageConfigOptionsWithS3ObjectVersion]:
1306
+ '''Configuration for plugins storage.'''
1307
+ result = self._values.get("plugins_config")
1308
+ return typing.cast(typing.Optional[DagStorageConfigOptionsWithS3ObjectVersion], result)
1183
1309
 
1184
1310
  @builtins.property
1185
1311
  def removal_policy(self) -> typing.Optional[_aws_cdk_ceddda9d.RemovalPolicy]:
@@ -1191,6 +1317,14 @@ class MWAAProps:
1191
1317
  result = self._values.get("removal_policy")
1192
1318
  return typing.cast(typing.Optional[_aws_cdk_ceddda9d.RemovalPolicy], result)
1193
1319
 
1320
+ @builtins.property
1321
+ def requirements_config(
1322
+ self,
1323
+ ) -> typing.Optional[DagStorageConfigOptionsWithS3ObjectVersion]:
1324
+ '''Configuration for requirements storage.'''
1325
+ result = self._values.get("requirements_config")
1326
+ return typing.cast(typing.Optional[DagStorageConfigOptionsWithS3ObjectVersion], result)
1327
+
1194
1328
  @builtins.property
1195
1329
  def sizing(self) -> typing.Optional["Sizing"]:
1196
1330
  '''Optional sizing configuration for the MWAA environment.
@@ -1200,6 +1334,14 @@ class MWAAProps:
1200
1334
  result = self._values.get("sizing")
1201
1335
  return typing.cast(typing.Optional["Sizing"], result)
1202
1336
 
1337
+ @builtins.property
1338
+ def startup_script_config(
1339
+ self,
1340
+ ) -> typing.Optional[DagStorageConfigOptionsWithS3ObjectVersion]:
1341
+ '''Configuration for startup script storage.'''
1342
+ result = self._values.get("startup_script_config")
1343
+ return typing.cast(typing.Optional[DagStorageConfigOptionsWithS3ObjectVersion], result)
1344
+
1203
1345
  @builtins.property
1204
1346
  def vpc(self) -> typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc]:
1205
1347
  '''The VPC in which to deploy the MWAA environment.
@@ -1240,9 +1382,12 @@ class PublicRoutingMWAA(
1240
1382
  environment_name: builtins.str,
1241
1383
  airflow_configuration_options: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
1242
1384
  bucket_name: typing.Optional[builtins.str] = None,
1243
- deploy_options: typing.Optional[typing.Union[DagStorageDeployOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1385
+ dags_config: typing.Optional[typing.Union[DagStorageConfigOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1386
+ plugins_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1244
1387
  removal_policy: typing.Optional[_aws_cdk_ceddda9d.RemovalPolicy] = None,
1388
+ requirements_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1245
1389
  sizing: typing.Optional["Sizing"] = None,
1390
+ startup_script_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1246
1391
  vpc: typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc] = None,
1247
1392
  ) -> None:
1248
1393
  '''
@@ -1252,9 +1397,12 @@ class PublicRoutingMWAA(
1252
1397
  :param environment_name: The name of the Airflow environment.
1253
1398
  :param airflow_configuration_options: Airflow configuration options as key-value pairs. These configuration options are passed to the Airflow environment.
1254
1399
  :param bucket_name: The name of the S3 bucket used for storing DAGs. If not provided, a default bucket is created.
1255
- :param deploy_options: Optional DAG storage deployment options. Configures how the DAGs are deployed to the S3 bucket.
1400
+ :param dags_config: Configuration for DAG storage.
1401
+ :param plugins_config: Configuration for plugins storage.
1256
1402
  :param removal_policy: The removal policy for the MWAA resources. Determines what happens to the resources when they are deleted. Defaults to 'RETAIN' if not specified.
1403
+ :param requirements_config: Configuration for requirements storage.
1257
1404
  :param sizing: Optional sizing configuration for the MWAA environment. Defines the compute resources.
1405
+ :param startup_script_config: Configuration for startup script storage.
1258
1406
  :param vpc: The VPC in which to deploy the MWAA environment. If not provided, a default VPC will be created.
1259
1407
  '''
1260
1408
  if __debug__:
@@ -1266,9 +1414,12 @@ class PublicRoutingMWAA(
1266
1414
  environment_name=environment_name,
1267
1415
  airflow_configuration_options=airflow_configuration_options,
1268
1416
  bucket_name=bucket_name,
1269
- deploy_options=deploy_options,
1417
+ dags_config=dags_config,
1418
+ plugins_config=plugins_config,
1270
1419
  removal_policy=removal_policy,
1420
+ requirements_config=requirements_config,
1271
1421
  sizing=sizing,
1422
+ startup_script_config=startup_script_config,
1272
1423
  vpc=vpc,
1273
1424
  )
1274
1425
 
@@ -1753,6 +1904,7 @@ class WebserverAccessMode(enum.Enum):
1753
1904
  __all__ = [
1754
1905
  "DagStorage",
1755
1906
  "DagStorageConfigOptions",
1907
+ "DagStorageConfigOptionsWithS3ObjectVersion",
1756
1908
  "DagStorageDeployOptions",
1757
1909
  "DagStorageProps",
1758
1910
  "EmailBackendOptions",
@@ -1780,13 +1932,12 @@ def _typecheckingstub__95a166027e8ebcfead2708b1c3388e60862a4fb6d86763bf56854f275
1780
1932
  id: builtins.str,
1781
1933
  *,
1782
1934
  bucket_name: typing.Optional[builtins.str] = None,
1783
- dag_s3_path: typing.Optional[builtins.str] = None,
1784
- deploy_options: typing.Optional[typing.Union[DagStorageDeployOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1935
+ dags_config: typing.Optional[typing.Union[DagStorageConfigOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1785
1936
  noncurrent_version_expiration: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
1786
- plugins_config: typing.Optional[typing.Union[DagStorageConfigOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1937
+ plugins_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1787
1938
  removal_policy: typing.Optional[_aws_cdk_ceddda9d.RemovalPolicy] = None,
1788
- requirements_config: typing.Optional[typing.Union[DagStorageConfigOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1789
- startup_script_config: typing.Optional[typing.Union[DagStorageConfigOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1939
+ requirements_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1940
+ startup_script_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1790
1941
  versioned: typing.Optional[builtins.bool] = None,
1791
1942
  ) -> None:
1792
1943
  """Type checking stubs"""
@@ -1795,6 +1946,17 @@ def _typecheckingstub__95a166027e8ebcfead2708b1c3388e60862a4fb6d86763bf56854f275
1795
1946
  def _typecheckingstub__85a9b5242a26a2093aa8052dd8b86bea06801d5a767c2e5f908776c3f849eb63(
1796
1947
  *,
1797
1948
  s3_path: builtins.str,
1949
+ deploy_options: typing.Optional[typing.Union[DagStorageDeployOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1950
+ local_path: typing.Optional[builtins.str] = None,
1951
+ ) -> None:
1952
+ """Type checking stubs"""
1953
+ pass
1954
+
1955
+ def _typecheckingstub__1fd77af7d832e6c1f66f71849ff7971c010e8282b5b3a43d573c7892c43539cf(
1956
+ *,
1957
+ s3_path: builtins.str,
1958
+ deploy_options: typing.Optional[typing.Union[DagStorageDeployOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1959
+ local_path: typing.Optional[builtins.str] = None,
1798
1960
  s3_object_version: typing.Optional[builtins.str] = None,
1799
1961
  ) -> None:
1800
1962
  """Type checking stubs"""
@@ -1802,9 +1964,9 @@ def _typecheckingstub__85a9b5242a26a2093aa8052dd8b86bea06801d5a767c2e5f908776c3f
1802
1964
 
1803
1965
  def _typecheckingstub__c4eb47db99cbba877092424afc09de8c308a38be2c61e698dd0c28933b9c3b42(
1804
1966
  *,
1967
+ exclude: typing.Optional[typing.Sequence[builtins.str]] = None,
1805
1968
  prune: typing.Optional[builtins.bool] = None,
1806
1969
  retain_on_delete: typing.Optional[builtins.bool] = None,
1807
- sources: typing.Optional[typing.Sequence[_aws_cdk_aws_s3_deployment_ceddda9d.ISource]] = None,
1808
1970
  ) -> None:
1809
1971
  """Type checking stubs"""
1810
1972
  pass
@@ -1812,13 +1974,12 @@ def _typecheckingstub__c4eb47db99cbba877092424afc09de8c308a38be2c61e698dd0c28933
1812
1974
  def _typecheckingstub__6a4bace9647a9566f3af4198e17ef015306e92a6d5f673b579ba6fdfcb5231da(
1813
1975
  *,
1814
1976
  bucket_name: typing.Optional[builtins.str] = None,
1815
- dag_s3_path: typing.Optional[builtins.str] = None,
1816
- deploy_options: typing.Optional[typing.Union[DagStorageDeployOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1977
+ dags_config: typing.Optional[typing.Union[DagStorageConfigOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1817
1978
  noncurrent_version_expiration: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
1818
- plugins_config: typing.Optional[typing.Union[DagStorageConfigOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1979
+ plugins_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1819
1980
  removal_policy: typing.Optional[_aws_cdk_ceddda9d.RemovalPolicy] = None,
1820
- requirements_config: typing.Optional[typing.Union[DagStorageConfigOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1821
- startup_script_config: typing.Optional[typing.Union[DagStorageConfigOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1981
+ requirements_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1982
+ startup_script_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1822
1983
  versioned: typing.Optional[builtins.bool] = None,
1823
1984
  ) -> None:
1824
1985
  """Type checking stubs"""
@@ -1838,7 +1999,7 @@ def _typecheckingstub__ebc587b767dfc724460675574ff2adf5d781edef0bcce6da7e68d7601
1838
1999
  *,
1839
2000
  airflow_version: builtins.str,
1840
2001
  dag_storage: DagStorage,
1841
- environment_name: builtins.str,
2002
+ name: builtins.str,
1842
2003
  sizing: Sizing,
1843
2004
  vpc: _aws_cdk_aws_ec2_ceddda9d.IVpc,
1844
2005
  airflow_configuration_options: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
@@ -1870,7 +2031,7 @@ def _typecheckingstub__d58cfc6f1183850b5b51999d54a17bf62c6f7b5c3c75133b721818d02
1870
2031
  *,
1871
2032
  airflow_version: builtins.str,
1872
2033
  dag_storage: DagStorage,
1873
- environment_name: builtins.str,
2034
+ name: builtins.str,
1874
2035
  sizing: Sizing,
1875
2036
  vpc: _aws_cdk_aws_ec2_ceddda9d.IVpc,
1876
2037
  airflow_configuration_options: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
@@ -1910,9 +2071,12 @@ def _typecheckingstub__e73d818937427f32bb22179ff7d13eb6aa0201131959780924f6ec21b
1910
2071
  environment_name: builtins.str,
1911
2072
  airflow_configuration_options: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
1912
2073
  bucket_name: typing.Optional[builtins.str] = None,
1913
- deploy_options: typing.Optional[typing.Union[DagStorageDeployOptions, typing.Dict[builtins.str, typing.Any]]] = None,
2074
+ dags_config: typing.Optional[typing.Union[DagStorageConfigOptions, typing.Dict[builtins.str, typing.Any]]] = None,
2075
+ plugins_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1914
2076
  removal_policy: typing.Optional[_aws_cdk_ceddda9d.RemovalPolicy] = None,
2077
+ requirements_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1915
2078
  sizing: typing.Optional[Sizing] = None,
2079
+ startup_script_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1916
2080
  vpc: typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc] = None,
1917
2081
  ) -> None:
1918
2082
  """Type checking stubs"""
@@ -1926,9 +2090,12 @@ def _typecheckingstub__5715af45a5664383ddb469b7bffe2c8a7d75c3dfe608847aae4c9fd79
1926
2090
  environment_name: builtins.str,
1927
2091
  airflow_configuration_options: typing.Optional[typing.Mapping[builtins.str, typing.Any]] = None,
1928
2092
  bucket_name: typing.Optional[builtins.str] = None,
1929
- deploy_options: typing.Optional[typing.Union[DagStorageDeployOptions, typing.Dict[builtins.str, typing.Any]]] = None,
2093
+ dags_config: typing.Optional[typing.Union[DagStorageConfigOptions, typing.Dict[builtins.str, typing.Any]]] = None,
2094
+ plugins_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1930
2095
  removal_policy: typing.Optional[_aws_cdk_ceddda9d.RemovalPolicy] = None,
2096
+ requirements_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1931
2097
  sizing: typing.Optional[Sizing] = None,
2098
+ startup_script_config: typing.Optional[typing.Union[DagStorageConfigOptionsWithS3ObjectVersion, typing.Dict[builtins.str, typing.Any]]] = None,
1932
2099
  vpc: typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc] = None,
1933
2100
  ) -> None:
1934
2101
  """Type checking stubs"""
@@ -32,7 +32,7 @@ import aws_cdk._jsii
32
32
  import constructs._jsii
33
33
 
34
34
  __jsii_assembly__ = jsii.JSIIAssembly.load(
35
- "cdk-mwaa", "0.0.2", __name__[0:-6], "cdk-mwaa@0.0.2.jsii.tgz"
35
+ "cdk-mwaa", "0.0.4", __name__[0:-6], "cdk-mwaa@0.0.4.jsii.tgz"
36
36
  )
37
37
 
38
38
  __all__ = [
Binary file
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: cdk-mwaa
3
- Version: 0.0.2
3
+ Version: 0.0.4
4
4
  Summary: cdk-mwaa
5
5
  Home-page: https://github.com/hupe1980/cdk-mwaa.git
6
6
  Author: hupe1980<frankhuebner1980@gmail.com>
@@ -51,6 +51,7 @@ yarn add cdk-mwaa
51
51
  Here is an example of how to use the `cdk-mwaa` construct library in your AWS CDK project:
52
52
 
53
53
  ```python
54
+ import * as path from 'node:path';
54
55
  import * as cdk from 'aws-cdk-lib';
55
56
  import * as mwaa from 'cdk-mwaa';
56
57
 
@@ -59,11 +60,15 @@ const stack = new cdk.Stack(app, 'MwaaStack');
59
60
 
60
61
  const dagStorage = new mwaa.DagStorage(stack, 'MyMwaaDagStorage', {
61
62
  bucketName: 'my-mwaa-dag-storage',
62
- removalPolicy: cdk.RemovalPolicy.DESTROY,
63
+ dagsConfig: {
64
+ localPath: path.join(__dirname, 'dags'),
65
+ s3Path: 'dags/',
66
+ },
67
+ // additional configuration options...
63
68
  });
64
69
 
65
70
  new mwaa.Environment(stack, 'MyMwaaEnvironment', {
66
- environmentName: 'my-mwaa-environment',
71
+ name: 'my-mwaa-environment',
67
72
  dagStorage,
68
73
  airflowVersion: '2.10.3',
69
74
  sizing: mwaa.Sizing.mw1Micro(),
@@ -88,17 +93,18 @@ const stack = new cdk.Stack(app, 'MwaaStack');
88
93
 
89
94
  const dagStorage = new mwaa.DagStorage(stack, 'MyMwaaDagStorage', {
90
95
  bucketName: 'my-mwaa-dag-storage',
91
- removalPolicy: cdk.RemovalPolicy.DESTROY,
96
+ // additional configuration options...
92
97
  });
93
98
 
94
99
  const environment = new mwaa.Environment(stack, 'MyMwaaEnvironment', {
95
- environmentName: 'my-mwaa-environment',
100
+ name: 'my-mwaa-environment',
96
101
  dagStorage,
97
102
  airflowVersion: '2.10.3',
98
103
  sizing: mwaa.Sizing.mw1Micro(),
99
104
  // additional configuration options...
100
105
  });
101
106
 
107
+ // Enabling Secrets Backend
102
108
  environment.enableSecretsBackend();
103
109
 
104
110
  app.synth();
@@ -0,0 +1,9 @@
1
+ cdk_mwaa/__init__.py,sha256=I1MZUu2ILYDE7e4b56WzzPDpEK3XNmr0k3TddV_Rh_w,100898
2
+ cdk_mwaa/py.typed,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
3
+ cdk_mwaa/_jsii/__init__.py,sha256=6LeXuTx1b6Os9D0Cmcc4jL1rW4uMlTKGbpsYp6GE25Y,1427
4
+ cdk_mwaa/_jsii/cdk-mwaa@0.0.4.jsii.tgz,sha256=3DVU74DzL8jtSxXgp3ixPMzRNLWLobv2eqIvIoffQLA,52464
5
+ cdk_mwaa-0.0.4.dist-info/LICENSE,sha256=GROW7AizgUVwWcX5o-CwAIpCxKEjgB76LUYIlvm6CRc,1052
6
+ cdk_mwaa-0.0.4.dist-info/METADATA,sha256=abbS_MB0WniAS1jY-Es0xh7-PT60mJvMA0RU9qIiEoo,3408
7
+ cdk_mwaa-0.0.4.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
8
+ cdk_mwaa-0.0.4.dist-info/top_level.txt,sha256=z7TehVmyHoAC8t6mK5tn4TX1KD56rdyY-knSDyjfhGU,9
9
+ cdk_mwaa-0.0.4.dist-info/RECORD,,
Binary file
@@ -1,9 +0,0 @@
1
- cdk_mwaa/__init__.py,sha256=oJfd3Mpa0GiQNrwu-JRzAidhrBuaXD2uocMc0wLGjLg,92129
2
- cdk_mwaa/py.typed,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
3
- cdk_mwaa/_jsii/__init__.py,sha256=M2W-pJo3mlWQwCiZhXg11xq_bXFoHr8PNkqlUoPwHVI,1427
4
- cdk_mwaa/_jsii/cdk-mwaa@0.0.2.jsii.tgz,sha256=9LXet-NVIuHtDX-_S1w4w3BoqJEkGXFLh_FtHNOVsOM,51353
5
- cdk_mwaa-0.0.2.dist-info/LICENSE,sha256=GROW7AizgUVwWcX5o-CwAIpCxKEjgB76LUYIlvm6CRc,1052
6
- cdk_mwaa-0.0.2.dist-info/METADATA,sha256=dp8V2iazqUGbNbQhB-XGuZOB3XIvofJlzzfIn706xi0,3274
7
- cdk_mwaa-0.0.2.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
8
- cdk_mwaa-0.0.2.dist-info/top_level.txt,sha256=z7TehVmyHoAC8t6mK5tn4TX1KD56rdyY-knSDyjfhGU,9
9
- cdk_mwaa-0.0.2.dist-info/RECORD,,