Cloudformation CloudFront CachePolicy showing invalid request provided

0

I am using AWS CLI together with a yaml file to deploy my CloudFront resource. I am aiming to add a CachePolicy to my CloudFront distribution but I am always getting an "Invalid request provided" error on Cloudformation in AWS console. Is my yaml wrong or am I missing something?

Here is a snippet of the cache policy and response headers policy I am using:Enter image description here

1 Antwort
2
Akzeptierte Antwort

If you have provided CookieBehavior, HeaderBehavior, and QueryStringBehavior with whitelist value, then you must also provide a list of values that must be included for those parameters. The values should be listed in the the corresponding Cookies, Headers, and QueryStrings parameter for each config.

Example for HeadersConfig:

          HeadersConfig: 
            HeaderBehavior: whitelist
            Headers:
              - Authorization
profile picture
joahna
beantwortet vor 2 Jahren
profile pictureAWS
EXPERTE
Toni_S
überprüft vor 2 Jahren

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen