@codedazur/cdk-docker-cluster 0.6.4 → 0.8.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.
package/CHANGELOG.md CHANGED
@@ -1,6 +1,28 @@
1
1
  # @codedazur/cdk-docker-cluster
2
2
 
3
- ## 2.0.5
3
+ ## 0.8.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [`d557d82`](https://github.com/codedazur/toolkit/commit/d557d822ffe8e42b0907f1d4e1a2b243f3430674) Thanks [@thijsdaniels](https://github.com/thijsdaniels)! - The AllViewer origin request policy is now used by default.
8
+
9
+ ### Patch Changes
10
+
11
+ - Updated dependencies [[`d557d82`](https://github.com/codedazur/toolkit/commit/d557d822ffe8e42b0907f1d4e1a2b243f3430674)]:
12
+ - @codedazur/cdk-site-distribution@0.3.0
13
+
14
+ ## 0.7.0
15
+
16
+ ### Minor Changes
17
+
18
+ - [`4f8716c`](https://github.com/codedazur/toolkit/commit/4f8716c534265493e708ede8239bd47d38ff83a4) Thanks [@thijsdaniels](https://github.com/thijsdaniels)! - The cache policy now defaults to the recommended policy for an Application Load Balancer origin.
19
+
20
+ ### Patch Changes
21
+
22
+ - Updated dependencies [[`4f8716c`](https://github.com/codedazur/toolkit/commit/4f8716c534265493e708ede8239bd47d38ff83a4), [`4f8716c`](https://github.com/codedazur/toolkit/commit/4f8716c534265493e708ede8239bd47d38ff83a4)]:
23
+ - @codedazur/cdk-site-distribution@0.2.0
24
+
25
+ ## 0.6.4
4
26
 
5
27
  ### Patch Changes
6
28
 
package/dist/index.js CHANGED
@@ -84,11 +84,23 @@ var DockerCluster = class extends import_constructs.Construct {
84
84
  return service;
85
85
  }
86
86
  createDistribution() {
87
+ const cachePolicy = import_aws_cloudfront.CachePolicy.fromCachePolicyId(
88
+ this,
89
+ "CachePolicy",
90
+ "4cc15a8a-d715-48a4-82b8-cc0b614638fe"
91
+ );
92
+ const originRequestPolicy = import_aws_cloudfront.OriginRequestPolicy.fromOriginRequestPolicyId(
93
+ this,
94
+ "OriginRequestPolicy",
95
+ "216adef6-5c7f-47e4-b989-5492eafa07d3"
96
+ );
87
97
  return new import_cdk_site_distribution.SiteDistribution(this, "Distribution", {
88
98
  ...this.props.distribution,
89
99
  origin: new import_aws_cloudfront_origins.LoadBalancerV2Origin(this.service.loadBalancer, {
90
100
  protocolPolicy: import_aws_cloudfront.OriginProtocolPolicy.HTTP_ONLY
91
- })
101
+ }),
102
+ cachePolicy,
103
+ originRequestPolicy
92
104
  });
93
105
  }
94
106
  getOutputDirectory() {
package/dist/index.mjs CHANGED
@@ -3,7 +3,11 @@ import {
3
3
  SiteDistribution
4
4
  } from "@codedazur/cdk-site-distribution";
5
5
  import { App } from "aws-cdk-lib";
6
- import { OriginProtocolPolicy } from "aws-cdk-lib/aws-cloudfront";
6
+ import {
7
+ CachePolicy,
8
+ OriginProtocolPolicy,
9
+ OriginRequestPolicy
10
+ } from "aws-cdk-lib/aws-cloudfront";
7
11
  import { LoadBalancerV2Origin } from "aws-cdk-lib/aws-cloudfront-origins";
8
12
  import { Platform } from "aws-cdk-lib/aws-ecr-assets";
9
13
  import {
@@ -65,11 +69,23 @@ var DockerCluster = class extends Construct {
65
69
  return service;
66
70
  }
67
71
  createDistribution() {
72
+ const cachePolicy = CachePolicy.fromCachePolicyId(
73
+ this,
74
+ "CachePolicy",
75
+ "4cc15a8a-d715-48a4-82b8-cc0b614638fe"
76
+ );
77
+ const originRequestPolicy = OriginRequestPolicy.fromOriginRequestPolicyId(
78
+ this,
79
+ "OriginRequestPolicy",
80
+ "216adef6-5c7f-47e4-b989-5492eafa07d3"
81
+ );
68
82
  return new SiteDistribution(this, "Distribution", {
69
83
  ...this.props.distribution,
70
84
  origin: new LoadBalancerV2Origin(this.service.loadBalancer, {
71
85
  protocolPolicy: OriginProtocolPolicy.HTTP_ONLY
72
- })
86
+ }),
87
+ cachePolicy,
88
+ originRequestPolicy
73
89
  });
74
90
  }
75
91
  getOutputDirectory() {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@codedazur/cdk-docker-cluster",
3
- "version": "0.6.4",
3
+ "version": "0.8.0",
4
4
  "main": ".dist/index.js",
5
5
  "module": "./dist/index.mjs",
6
6
  "types": "./dist/index.d.ts",
@@ -27,7 +27,7 @@
27
27
  "constructs": ">=10"
28
28
  },
29
29
  "dependencies": {
30
- "@codedazur/cdk-site-distribution": "^0.1.6"
30
+ "@codedazur/cdk-site-distribution": "^0.3.0"
31
31
  },
32
32
  "devDependencies": {
33
33
  "@types/node": "^20.14.9",