aghadiry / serverless-cloudfront-invalidate

Serverless plugin that allows you to invalidate Cloudfront Cache
MIT License
29 stars 22 forks source link

[Bug] Assumptions about the stackName break this plugins #11

Closed egut closed 4 years ago

egut commented 5 years ago

I started to get:

DistributionIdKey: WebAppCloudFrontDistribution
Failed to get DistributionId from stack output. Please check your serverless template.

The resaon are that I set my stack name in provider.stackName. You assume the stackname but there are a API for that. See: https://github.com/serverless/serverless/blob/3408a4ee15562e2249951f3d76d08e9ce6ff70cc/lib/plugins/aws/lib/naming.js