Agent skill

cdn-setup

Configure CDNs for content delivery. Set up CloudFront, Cloudflare, and Fastly. Use when optimizing global content delivery.

Stars 163
Forks 31

Install this agent skill to your Project

npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/other/cdn-setup

Metadata

Additional technical details for this skill

author
devops-skills
version
1.0

SKILL.md

CDN Setup

Configure content delivery networks.

AWS CloudFront

bash
aws cloudfront create-distribution --distribution-config '{
  "CallerReference": "my-distribution",
  "Origins": {
    "Quantity": 1,
    "Items": [{
      "Id": "myS3Origin",
      "DomainName": "mybucket.s3.amazonaws.com",
      "S3OriginConfig": {"OriginAccessIdentity": ""}
    }]
  },
  "DefaultCacheBehavior": {
    "TargetOriginId": "myS3Origin",
    "ViewerProtocolPolicy": "redirect-to-https",
    "CachePolicyId": "658327ea-f89d-4fab-a63d-7e88639e58f6"
  },
  "Enabled": true
}'

Cloudflare

bash
# Via API
curl -X POST "https://api.cloudflare.com/client/v4/zones" \
  -H "Authorization: Bearer $TOKEN" \
  -d '{"name":"example.com","jump_start":true}'

Cache Headers

nginx
location ~* \.(jpg|jpeg|png|gif|ico|css|js)$ {
    expires 30d;
    add_header Cache-Control "public, immutable";
}

Best Practices

  • Set appropriate cache headers
  • Use cache invalidation sparingly
  • Implement cache warming
  • Monitor cache hit ratios

Expand your agent's capabilities with these related and highly-rated skills.

Didn't find tool you were looking for?

Be as detailed as possible for better results