{
  "name": "static-assets",
  "version": "1.0.0",
  "kind": "l2",
  "depth": 1,
  "description": "A production-ready pattern that references the s3, cloudfront, and waf primitives to deploy a static asset site with a CloudFront CDN edge and WAF protection.",
  "children": [
    {"id": "s3", "module": "s3@1.0.0"},
    {"id": "cloudfront", "module": "cloudfront@1.0.0"},
    {"id": "waf", "module": "waf@1.0.0"},
    {"id": "kms", "module": "kms-key@1.0.0"}
  ],
  "wires": [
    {"from": "contract.inputs.bucket_name", "to": "s3.inputs.bucket_name"},
    {"from": "contract.inputs.region", "to": "s3.inputs.region"},
    {"from": "contract.inputs.region", "to": "cloudfront.inputs.region"},
    {"from": "contract.inputs.region", "to": "waf.inputs.region"},
    {"from": "s3.outputs.bucket_regional_domain_name", "to": "cloudfront.inputs.bucket_regional_domain_name"},
    {"from": "waf.outputs.web_acl_arn", "to": "cloudfront.inputs.waf_web_acl_arn"},
    {"from": "contract.inputs.region", "to": "kms.inputs.region"},
    {"from": "kms.outputs.kms_key_arn", "to": "s3.inputs.kms_key_arn"},
    {"from": "contract.inputs.default_ttl", "to": "cloudfront.inputs.default_ttl"},
    {"from": "contract.inputs.max_ttl", "to": "cloudfront.inputs.max_ttl"},
    {"from": "contract.inputs.price_class", "to": "cloudfront.inputs.price_class"},
    {"from": "contract.inputs.viewer_protocol_policy", "to": "cloudfront.inputs.viewer_protocol_policy"}
  ],
  "outputs": [
    {"from": "cloudfront.outputs.distribution_domain_name", "to": "stack.outputs.distribution_domain_name"},
    {"from": "s3.outputs.bucket_arn", "to": "stack.outputs.bucket_arn"},
    {"from": "waf.outputs.web_acl_arn", "to": "stack.outputs.web_acl_arn"},
    {"from": "kms.outputs.kms_key_arn", "to": "stack.outputs.kms_key_arn"}
  ]
}