{
  "$schema": "./node_modules/wrangler/config-schema.json",
  "// Comment": "Full SSR configuration for Astro on Cloudflare Workers",
  "name": "your-app-name",
  "compatibility_date": "2025-01-19",
  "compatibility_flags": ["nodejs_compat", "disable_nodejs_process_v2"],
  "assets": {
    "directory": "./dist",
    "binding": "ASSETS"
  },
  "vars": {
    "ENVIRONMENT": "production",
    "PUBLIC_SITE_URL": "https://your-app-name.workers.dev",
    "API_URL": "https://api.example.com"
  },
  "env": {
    "staging": {
      "name": "your-app-name-staging",
      "vars": {
        "ENVIRONMENT": "staging",
        "PUBLIC_SITE_URL": "https://staging-your-app-name.workers.dev",
        "API_URL": "https://staging-api.example.com"
      }
    },
    "production": {
      "name": "your-app-name-production",
      "vars": {
        "ENVIRONMENT": "production",
        "PUBLIC_SITE_URL": "https://your-app-name.workers.dev",
        "API_URL": "https://api.example.com"
      }
    }
  },
  "// Comment bindings": "Configure Cloudflare bindings for your SSR app",
  "kv_namespaces": [
    {
      "binding": "CACHE",
      "id": "your-kv-namespace-id"
    }
  ],
  "d1_databases": [
    {
      "binding": "DB",
      "database_name": "my-database",
      "database_id": "your-d1-database-id"
    }
  ],
  "r2_buckets": [
    {
      "binding": "STORAGE",
      "bucket_name": "my-storage-bucket"
    }
  ]
}
