AI-Powered Multi-Cloud Deployment Platform
Deploy your applications to AWS, GCP, or Azure with intelligent AI agents that analyze your project, generate deployment plans, and execute real cloud deploymentsβall from a single CLI.
- Smart Project Analysis - Automatically detects your tech stack and dependencies
- Intelligent Planning - AI generates optimal deployment strategies
- Environment Validation - Validates cloud credentials and configurations
Deploy to 3 major cloud providers with 13 deployment targets:
| Cloud | Container | Serverless | Static Sites | PaaS |
|---|---|---|---|---|
| AWS | ECS Fargate | Lambda | S3 | - |
| GCP | Cloud Run | Cloud Functions | Firebase + Storage | App Engine |
| Azure | Container Apps | Functions | Static Web Apps + Blob | App Service |
- Comprehensive Logging - Session-based logs with 5 levels
- Error Handling - Friendly messages with recovery suggestions
- Deployment History - Complete audit trail with analytics
- Cost Tracking - Estimated costs per deployment
- Performance Monitoring - Duration and success rate tracking
- Human-in-the-Loop - Approval gates before deployment
- Suspend/Resume - Review plans before proceeding
- Multi-Step Orchestration - Automated multi-phase deployments
Before using Agent Cloud, ensure you have:
- AWS CLI - For AWS deployments (Install)
- gcloud CLI - For GCP deployments (Install)
- Azure CLI - For Azure deployments (Install)
# Clone the repository
git clone https://github.com/intojhanurag/agent-cloud.git
cd agent-cloud
# Install dependencies
pnpm install
# Build the project
pnpm build
# Make CLI globally available
pnpm link --globalChoose your cloud provider and authenticate:
For AWS:
aws configure
# Enter your AWS Access Key ID, Secret Access Key, and regionFor GCP:
gcloud auth login
gcloud config set project YOUR_PROJECT_IDFor Azure:
az login
az account set --subscription YOUR_SUBSCRIPTION_IDCreate a .env file in the project root:
# AI Provider (Choose one)
OPENAI_API_KEY=your_openai_api_key_here
# OR use Google Gemini
GOOGLE_GENERATIVE_AI_API_KEY=your_gemini_api_key_here
# Optional - Cloud configurations
AWS_REGION=us-east-1
GCLOUD_PROJECT=your-gcp-project
GCLOUD_REGION=us-central1
AZURE_RESOURCE_GROUP=agent-cloud-rg
AZURE_LOCATION=eastus# Navigate to your project directory
cd /path/to/your/project
# Deploy to AWS (interactive mode)
cloud-agent deploy --cloud aws
# Review the deployment plan
# Approve when ready
# OR: Deploy with auto-approval
cloud-agent deploy --cloud aws --yesThat's it! Your application is now deployed to the cloud!
# Deploy to cloud
cloud-agent deploy --cloud <aws|gcp|azure> [--yes]
# View deployment status
cloud-agent status
# List workflow history
cloud-agent workflows
# View help
cloud-agent --helpWhen you run cloud-agent deploy, here's what happens:
Phase 1: Environment Validation
- Validates cloud credentials
- Checks CLI installation
- Verifies network connectivity
Phase 2: Project Analysis
- Detects project type (static, API, container)
- Identifies runtime and framework
- Analyzes dependencies
Phase 3: Deployment Planning
- Generates cloud-specific plan
- Estimates costs
- Prepares deployment commands
Phase 4: Human Approval
- Shows deployment plan
- Waits for confirmation
- (Skip with --yes flag)
Phase 5: Cloud Deployment
- Authenticates with cloud provider
- Creates cloud resources
- Deploys your application
- Returns deployment URL
Static Sites - S3
# Build your static site
npm run build
# Deploy to AWS S3
cloud-agent deploy --cloud aws --yesAPIs/Containers - ECS Fargate
# Deploy Node.js API
cloud-agent deploy --cloud aws --yes
# Your app will be containerized and deployed to ECSRequired AWS Permissions:
- ECS (Fargate)
- EC2 (VPC, Security Groups)
- S3 (for static sites)
- IAM (for service roles)
Static Sites - Firebase Hosting
# Deploy to Firebase (best static hosting)
cloud-agent deploy --cloud gcp --yesAPIs/Containers - Cloud Run
# Deploy to Cloud Run (simplest container platform)
cloud-agent deploy --cloud gcp --yesRequired GCP APIs:
- Cloud Run API
- Cloud Build API
- Firebase Hosting API (for static sites)
- Cloud Storage API
Static Sites - Static Web Apps
# Deploy to Azure Static Web Apps (with global CDN)
cloud-agent deploy --cloud azure --yesAPIs/Containers - Container Apps
# Deploy to Azure Container Apps
cloud-agent deploy --cloud azure --yesRequired Azure Services:
- Container Apps
- Container Registry
- Static Web Apps (for static sites)
- Resource Groups
Agent Cloud automatically tracks all deployments with detailed analytics.
# View logs from last deployment
cat .agent-cloud/logs/deployment-*.log
# View deployment history
cat .agent-cloud/config.jsonYour deployment history is stored in .agent-cloud/config.json:
{
"version": "1.0.0",
"projectName": "my-app",
"defaultCloud": "aws",
"deployments": [
{
"id": "1737363780000",
"timestamp": "2026-01-20T12:23:00.000Z",
"cloud": "aws",
"projectPath": "./",
"success": true,
"deploymentUrl": "https://my-app.aws.com",
"resources": {
"cluster": "my-cluster",
"service": "my-service"
},
"cost": 45.00,
"duration": 142500
}
],
"preferences": {
"logLevel": "info",
"region": {
"aws": "us-east-1",
"gcp": "us-central1",
"azure": "eastus"
}
}
}View deployment statistics programmatically:
import { getConfigManager } from './src/utils/config.js';
const config = getConfigManager();
const stats = config.getStats();
console.log('Total Deployments:', stats.total);
console.log('Success Rate:', (stats.successful / stats.total * 100).toFixed(1) + '%');
console.log('Total Cost:', '$' + stats.totalCost.toFixed(2) + '/month');
console.log('Average Duration:', (stats.averageDuration / 1000).toFixed(1) + 's');Want to see a full working example? Check out our Simple Node.js API Demo!
This complete example includes:
- β Full REST API with CRUD operations
- β Docker configuration for all cloud providers
- β Comprehensive deployment instructions
- β API testing scripts
- β Step-by-step deployment guide
Quick start:
cd examples/simple-nodejs-api
npm install
npm start
# Then deploy to any cloud:
cloud-agent deploy --cloud awsπ Read the full example README β
# In your React project
cd my-react-app
# Build the production bundle
npm run build
# Deploy to AWS S3
cloud-agent deploy --cloud aws --yes
# Output:
# Deployment to AWS completed successfully!
# URL: https://my-react-app.s3-website-us-east-1.amazonaws.com
# Duration: 45.2s
# Estimated Cost: $3.00/month# In your Node.js API project
cd my-node-api
# Deploy to Cloud Run
cloud-agent deploy --cloud gcp --yes
# Output:
# Deployment to GCP completed successfully!
# URL: https://my-node-api-abc123.run.app
# Duration: 127.8s
# Estimated Cost: $25.00/month# In your Next.js project
cd my-nextjs-app
# Build the app
npm run build
# Deploy to Azure Static Web Apps
cloud-agent deploy --cloud azure --yes
# Output:
# Deployment to Azure completed successfully!
# URL: https://my-nextjs-app.azurestaticapps.net
# Duration: 98.5s
# Estimated Cost: $0.00/month (Free tier)# AI Configuration (Choose one)
OPENAI_API_KEY=sk-... # Option 1: OpenAI API key
GOOGLE_GENERATIVE_AI_API_KEY=... # Option 2: Google Gemini API key
# AWS Configuration
AWS_REGION=us-east-1 # Default: us-east-1
AWS_ACCESS_KEY_ID=AKIA... # Optional: AWS credentials
AWS_SECRET_ACCESS_KEY=... # Optional: AWS credentials
# GCP Configuration
GCLOUD_PROJECT=my-project # Required for GCP
GCLOUD_REGION=us-central1 # Default: us-central1
GOOGLE_CLOUD_PROJECT=my-project # Alternative to GCLOUD_PROJECT
# Azure Configuration
AZURE_SUBSCRIPTION_ID=... # Required for Azure
AZURE_RESOURCE_GROUP=agent-cloud-rg # Default: agent-cloud-rg
AZURE_LOCATION=eastus # Default: eastus
AZURE_TENANT_ID=... # Optional: Service principal
AZURE_CLIENT_ID=... # Optional: Service principal
AZURE_CLIENT_SECRET=... # Optional: Service principal
# Logging
LOG_LEVEL=info # Options: debug, info, success, warn, errorYou can set default preferences:
import { getConfigManager } from './src/utils/config.js';
const config = getConfigManager();
// Set default cloud provider
config.setDefaultCloud('aws');
// Enable auto-approval (skip confirmation)
config.setAutoApprove(true);
// Set preferred regions
config.setPreferredRegion('aws', 'us-west-2');
config.setPreferredRegion('gcp', 'europe-west1');
config.setPreferredRegion('azure', 'westus2');AWS:
# Check AWS credentials
aws sts get-caller-identity
# Reconfigure
aws configureGCP:
# Check authentication status
gcloud auth list
# Reauthenticate
gcloud auth loginAzure:
# Check login status
az account show
# Relogin
az loginMake sure you've set either the OPENAI_API_KEY or GOOGLE_GENERATIVE_AI_API_KEY environment variable:
# Option 1: Add OpenAI key to .env file
echo "OPENAI_API_KEY=sk-your-key-here" >> .env
# Option 2: Add Gemini key to .env file
echo "GOOGLE_GENERATIVE_AI_API_KEY=your-key-here" >> .env
# Or export temporarily
export OPENAI_API_KEY=sk-your-key-here
# OR
export GOOGLE_GENERATIVE_AI_API_KEY=your-key-hereEnsure the package is linked globally:
cd /path/to/agent-cloud
pnpm link --globalThis is normal! Cloud deployments can take 2-5 minutes depending on:
- Cloud provider
- Resource creation
- Container builds
- Network latency
Watch the logs for progress:
tail -f .agent-cloud/logs/deployment-*.logagent-cloud/
βββ bin/
β βββ cli.ts # CLI entry point
βββ src/
β βββ cli/
β β βββ index.ts # CLI commands
β β βββ workflow-commands.ts # Workflow commands
β βββ mastra/
β β βββ agents/
β β β βββ index.ts # AI agents (Validator, Analyzer, Deployment)
β β βββ workflows/
β β β βββ deployment.ts # Deployment workflow
β β βββ index.ts # Mastra instance
β βββ providers/
β β βββ aws/index.ts # AWS provider
β β βββ gcp/index.ts # GCP provider
β β βββ azure/index.ts # Azure provider
β βββ utils/
β βββ logger.ts # Logging system
β βββ error-handler.ts # Error handling
β βββ config.ts # Configuration management
βββ .agent-cloud/
β βββ logs/ # Deployment logs
β βββ config.json # Configuration & history
βββ .env # Environment variables
βββ package.json
βββ README.md
- Never commit credentials - Use environment variables
- Use IAM roles - When deploying from CI/CD
- Rotate API keys - Regularly update OpenAI and cloud keys
- Review logs - Check
.agent-cloud/logs/for sensitive data - Use service principals - For production Azure deployments
- Enable MFA - On all cloud accounts
We welcome contributions! Here's how to get started:
# Fork the repository
# Clone your fork
git clone https://github.com/intojhanurag/agent-cloud.git
# Create a feature branch
git checkout -b feature/amazing-feature
# Make your changes and commit
git commit -m "Add amazing feature"
# Push to your fork
git push origin feature/amazing-feature
# Open a Pull RequestThis project is licensed under the MIT License - see the LICENSE file for details.
Built with:
- Mastra - AI agent framework
- OpenAI - AI models
- Google Gemini - AI models (alternative)
- TypeScript - Type safety
- Commander.js - CLI framework
- Documentation: Read the docs
- Website (local landing): Website app (follow
website/README.mdto preview) - Issues: GitHub Issues
- Discussions: GitHub Discussions
- Support for more cloud providers (DigitalOcean, Cloudflare)
- Rollback capabilities
- Multi-region deployments
- Database provisioning
- CI/CD integration templates
- Web UI dashboard
- Terraform export
- Cost optimization recommendations
Built with β€οΈ by ojha_verse
Star us on GitHub if you find this useful!

