Skip to content

Commit

Permalink
fix dependency for asset deploy rewrite
Browse files Browse the repository at this point in the history
  • Loading branch information
revmischa committed Nov 9, 2022
1 parent 0c386e0 commit 58c4b9d
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/Nextjs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -267,9 +267,7 @@ export class Nextjs extends Construct {
? this.createCloudFrontDistributionForStub()
: this.createCloudFrontDistribution();
// wait for asset deployments to finish
this.assetsDeployment.deployments.forEach((s3Deployment) =>
this.distribution.node.addDependency(s3Deployment.deployedBucket)
);
this.assetsDeployment.deployments.forEach((s3Deployment) => this.distribution.node.addDependency(s3Deployment));

// // Invalidate CloudFront (might already be handled by deployments?)
// const invalidationCR = this.createCloudFrontInvalidation();
Expand Down

0 comments on commit 58c4b9d

Please sign in to comment.