Skip to content

⚙️ FEATURE-#173: Add dotflow cloud CLI for cross-cloud infrastructure generation#183

Merged
FernandoCelmer merged 44 commits intodevelopfrom
feature/173
Apr 8, 2026
Merged

⚙️ FEATURE-#173: Add dotflow cloud CLI for cross-cloud infrastructure generation#183
FernandoCelmer merged 44 commits intodevelopfrom
feature/173

Conversation

@FernandoCelmer
Copy link
Copy Markdown
Member

@FernandoCelmer FernandoCelmer commented Apr 7, 2026

Description

Cloud CLI

  • dotflow/cli/commands/cloud.pyCloudGenerateCommand and CloudListCommand using local template clone
  • dotflow/cli/commands/deploy.pyDeployCommand routing to platform-specific deployers
  • dotflow/cli/setup.py — Register cloud and deploy subcommands

Cloud Deploy Module (dotflow/cloud/)

  • core.py — ABCs: Registry, RoleManager, LogManager, ObjectStorage, Queue, EventScheduler, Deployer
  • aws/base_lambda_deployer.py — Shared logic for all Lambda variants (init, setup, create/update function)
  • aws/lambda_deployer.py — Lambda + EventBridge schedule trigger
  • aws/lambda_api_deployer.py — Lambda + API Gateway (HTTP API)
  • aws/lambda_s3_deployer.py — Lambda + S3 notification trigger
  • aws/lambda_sqs_deployer.py — Lambda + SQS event source mapping
  • aws/ecs_deployer.py — ECS Fargate task definition + cluster
  • aws/constants.py — AWS error messages
  • aws/services/ecr.py — ECR registry (Registry ABC)
  • aws/services/iam.py — IAM roles (RoleManager ABC)
  • aws/services/cloudwatch.py — CloudWatch log groups (LogManager ABC)
  • aws/services/s3.py — S3 object storage (ObjectStorage ABC)
  • gcp/cloudrun_deployer.py — Cloud Run deployer (Cloud Build + Run SDK)
  • gcp/services/gcs.py — GCS object storage (ObjectStorage ABC)
  • gcp/services/artifact_registry.py — Artifact Registry (Registry ABC)
  • gcp/services/apis.py — GCP API enablement via Service Usage SDK
  • gcp/constants.py — GCP error messages
  • github/actions_deployer.py — GitHub Actions deployer (PyGithub + GitPython SDK)
  • github/constants.py — GitHub error messages

Refactored Providers

  • providers/storage_s3.py — Now uses cloud.aws.services.s3.S3
  • providers/storage_gcs.py — Now uses cloud.gcp.services.gcs.GCS

Settings & Logging

  • settings.py — Added TEMPLATE_REPO, TEMPLATE_BRANCH, TEMPLATE_CLOUD_DIR, DOTFLOW_OUTPUT_PATH env var
  • logging.py — Removed mkdir and file handler (fixes Lambda read-only filesystem)

Documentation

  • docs/nav/cloud/ — 34 platform pages (Docker, AWS Lambda/ECS variants, GCP Cloud Run, Kubernetes, GitHub Actions, Azure, Heroku, Fly.io, Railway, Render, DigitalOcean, and more)
  • docs/nav/cloud/index.md — Overview with cards grouped by provider
  • docs/nav/concepts/concept-providers.md — Updated with Tracer, Metrics, Sentry, pip extras table
  • docs/nav/how-to/index.md — Removed Providers card (moved to Integrations)
  • README.md — Revamped with sales pitch, cloud deploy table, observability, features in expand, documentation links
  • docs/index.md — Replaced gif with png

Tests

  • tests/cloud/aws/ — 18 tests (LambdaDeployer, LambdaApiDeployer, LambdaS3Deployer, LambdaSQSDeployer, ECSDeployer, S3 service)
  • tests/cloud/gcp/ — 4 tests (GCS service)
  • tests/cloud/github/ — 6 tests (ActionsDeployer)
  • tests/providers/ — Updated StorageS3 and StorageGCS tests for new architecture

Optional Dependencies

  • deploy-aws — boto3
  • deploy-gcp — google-cloud-run, google-cloud-build, google-cloud-artifact-registry, google-cloud-service-usage, google-cloud-storage, google-auth
  • deploy-github — PyGithub, GitPython

Motivation and Context

Enables users to generate infrastructure files and deploy dotflow pipelines to any major cloud provider from the CLI. Templates are hosted in dotflow-io/template and fetched at runtime.

The cloud module follows a clean architecture with ABCs for all services (Registry, RoleManager, LogManager, ObjectStorage, Queue, EventScheduler, Deployer), allowing new cloud providers to be added by implementing the interfaces.

Closes #173

Types of changes

  • New feature (change which adds functionality)
  • Documentation

Checklist

  • I have performed a self-review of my own code
  • I have added tests that prove my fix is effective or that my feature works
  • I have updated the CHANGELOG
  • I have updated the documentation accordingly

@FernandoCelmer FernandoCelmer added the enhancement New feature or request label Apr 7, 2026
FernandoCelmer and others added 28 commits April 7, 2026 01:51
@FernandoCelmer FernandoCelmer added the documentation Improvements or additions to documentation label Apr 8, 2026
@FernandoCelmer FernandoCelmer merged commit 9b14f9e into develop Apr 8, 2026
10 checks passed
@FernandoCelmer FernandoCelmer deleted the feature/173 branch April 8, 2026 07:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants