We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
With a cache policy like this:
const cachePolicy = new aws.cloudfront.CachePolicy('api-cache-policy', { comment: "api requests with CORS caching enabled", minTtl: 0, defaultTtl: 0, maxTtl: 86400, parametersInCacheKeyAndForwardedToOrigin: { headersConfig: {headerBehavior: "whitelist", headers: {items: headers}}, cookiesConfig: {cookieBehavior: "none"}, queryStringsConfig: {queryStringBehavior: "all"} } })
The creation of the policy works as expected, however subsequent updates fail because the policy is sent without the defualtTtl:
debug: Updating CloudFront Cache Policy: ({ debug: CachePolicyConfig: { debug: Comment: "api requests with CORS caching enabled", debug: MaxTTL: 86400, debug: MinTTL: 0, debug: Name: "api-cache-policy-f7e76dd", debug: ParametersInCacheKeyAndForwardedToOrigin: { debug: CookiesConfig: { debug: CookieBehavior: "none" debug: }, debug: EnableAcceptEncodingBrotli: false, debug: EnableAcceptEncodingGzip: false, debug: HeadersConfig: { debug: HeaderBehavior: "whitelist", debug: Headers: { debug: Items: [ debug: "Origin", debug: "Accept", debug: "Access-Control-Request-Method", debug: "Accept-Language", debug: "CloudFront-Viewer-Country", debug: "Access-Control-Request-Headers" debug: ], debug: Quantity: 6 debug: } debug: }, debug: QueryStringsConfig: { debug: QueryStringBehavior: "all" debug: } debug: } debug: }, debug: Id: "9d6fb6e8-d6d1-4d9c-888e-27d1dfc1ffa1", debug: IfMatch: "E23ZP02F085DFQ" debug: })
error: 1 error occurred: * updating urn:pulumi:scott::api::aws:cloudfront/cachePolicy:CachePolicy::api-cache-policy: 1 error occurred: * error updating CloudFront Cache Policy (9d6fb6e8-d6d1-4d9c-888e-27d1dfc1ffa1): InvalidArgument: The parameter DefaultTTL is required. status code: 400, request id: 8aadfa77-6a68-4138-b40e-ecd3278ef889
pulumi v3.17.1 pulumi-aws 4.28.0
The text was updated successfully, but these errors were encountered:
This was fixed recently in hashicorp/terraform-provider-aws#21793 and will be picked up on the next release of the provider.
Sorry, something went wrong.
closing this out as we have since updated to a version that picks this up
No branches or pull requests
Hello!
Issue details
With a cache policy like this:
The creation of the policy works as expected, however subsequent updates fail because the policy is sent without the defualtTtl:
Versions
pulumi v3.17.1
pulumi-aws 4.28.0
The text was updated successfully, but these errors were encountered: