File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -90,6 +90,17 @@ resource "aws_s3_bucket_website_configuration" "bucket" {
9090 ])
9191}
9292
93+ resource "aws_cloudfront_response_headers_policy" "csp" {
94+ name = " colorcop-csp-policy"
95+
96+ security_headers_config {
97+ content_security_policy {
98+ override = true
99+ content_security_policy = " default-src 'self'; script-src 'self' 'unsafe-eval' https://pagead2.googlesyndication.com https://googleads.g.doubleclick.net https://cdnjs.cloudflare.com; style-src 'self' https://cdnjs.cloudflare.com 'unsafe-inline'; img-src 'self' data: https://pagead2.googlesyndication.com https://googleads.g.doubleclick.net;"
100+ }
101+ }
102+ }
103+
93104resource "aws_cloudfront_distribution" "distribution" {
94105 aliases = [local . www_domain , var . domain ]
95106 comment = " Cloudfront distribution for ${ var . domain } "
You can’t perform that action at this time.
0 commit comments