// Deploy and manage cloud infrastructure on Cloudflare (Workers, R2, D1, KV, Pages, Durable Objects, Browser Rendering), Docker containers, and Google Cloud Platform (Compute Engine, GKE, Cloud Run, App Engine, Cloud Storage). Use when deploying serverless functions to the edge, configuring edge computing solutions, managing Docker containers and images, setting up CI/CD pipelines, optimizing cloud infrastructure costs, implementing global caching strategies, working with cloud databases, or building cloud-native applications.
| name | devops |
| description | Deploy and manage cloud infrastructure on Cloudflare (Workers, R2, D1, KV, Pages, Durable Objects, Browser Rendering), Docker containers, and Google Cloud Platform (Compute Engine, GKE, Cloud Run, App Engine, Cloud Storage). Use when deploying serverless functions to the edge, configuring edge computing solutions, managing Docker containers and images, setting up CI/CD pipelines, optimizing cloud infrastructure costs, implementing global caching strategies, working with cloud databases, or building cloud-native applications. |
| license | MIT |
| version | 1.0.0 |
Comprehensive guide for deploying and managing cloud infrastructure across Cloudflare edge platform, Docker containerization, and Google Cloud Platform.
Use this skill when:
Best For:
Key Products:
Cost Profile: Pay-per-request, generous free tier, zero egress fees
Best For:
Key Capabilities:
Cost Profile: Infrastructure cost only (compute + storage)
Best For:
Key Services:
Cost Profile: Varied pricing, sustained use discounts, committed use contracts
# Install Wrangler CLI
npm install -g wrangler
# Create and deploy Worker
wrangler init my-worker
cd my-worker
wrangler deploy
See: references/cloudflare-workers-basics.md
# Create Dockerfile
cat > Dockerfile <<EOF
FROM node:20-alpine
WORKDIR /app
COPY package*.json ./
RUN npm ci --production
COPY . .
EXPOSE 3000
CMD ["node", "server.js"]
EOF
# Build and run
docker build -t myapp .
docker run -p 3000:3000 myapp
See: references/docker-basics.md
# Install and authenticate
curl https://sdk.cloud.google.com | bash
gcloud init
gcloud auth login
# Deploy to Cloud Run
gcloud run deploy my-service \
--image gcr.io/project/image \
--region us-central1
See: references/gcloud-platform.md
cloudflare-platform.md - Edge computing overview, key componentscloudflare-workers-basics.md - Getting started, handler types, basic patternscloudflare-workers-advanced.md - Advanced patterns, performance, optimizationcloudflare-workers-apis.md - Runtime APIs, bindings, integrationscloudflare-r2-storage.md - R2 object storage, S3 compatibility, best practicescloudflare-d1-kv.md - D1 SQLite database, KV store, use casesbrowser-rendering.md - Puppeteer/Playwright automation on Cloudflaredocker-basics.md - Core concepts, Dockerfile, images, containersdocker-compose.md - Multi-container apps, networking, volumesgcloud-platform.md - GCP overview, gcloud CLI, authenticationgcloud-services.md - Compute Engine, GKE, Cloud Run, App Enginescripts/cloudflare-deploy.py - Automate Cloudflare Worker deploymentsscripts/docker-optimize.py - Analyze and optimize Dockerfiles# Cloudflare Workers (API Gateway)
# -> Docker containers on Cloud Run (Backend Services)
# -> R2 (Object Storage)
# Benefits:
# - Edge caching and routing
# - Containerized business logic
# - Global distribution
# Build stage
FROM node:20-alpine AS build
WORKDIR /app
COPY package*.json ./
RUN npm ci
COPY . .
RUN npm run build
# Production stage
FROM node:20-alpine
WORKDIR /app
COPY --from=build /app/dist ./dist
COPY --from=build /app/node_modules ./node_modules
USER node
CMD ["node", "dist/server.js"]
# 1. Build: Docker multi-stage build
# 2. Test: Run tests in container
# 3. Push: Push to registry (GCR, Docker Hub)
# 4. Deploy: Deploy to Cloudflare Workers / Cloud Run
# 5. Verify: Health checks and smoke tests
| Need | Choose |
|---|---|
| Sub-50ms latency globally | Cloudflare Workers |
| Large file storage (zero egress) | Cloudflare R2 |
| SQL database (global reads) | Cloudflare D1 |
| Containerized workloads | Docker + Cloud Run/GKE |
| Enterprise Kubernetes | GKE |
| Managed relational DB | Cloud SQL |
| Static site + API | Cloudflare Pages |
| WebSocket/real-time | Cloudflare Durable Objects |
| ML/AI pipelines | GCP Vertex AI |
| Browser automation | Cloudflare Browser Rendering |
wrangler devwrangler deploy