Skip to main content

Parallel provisioning and orchestration for cross-cloud optimized compute

Project description

๐Ÿš€ Terradev CLI - Cross-Cloud Compute Optimization Platform

Parallel provisioning and orchestration for cross-cloud optimized compute.

Terradev operates faster than any sequential tool by orders of magnitude to find and stage datasets, then deploy optimal compute instances across multiple cloud providers simultaneously.


๐ŸŽฏ Overview

Terradev is a CLI tool that fits as a set of procurement heuristics in-between tools like Grafana, Kubernetes and cloud-compute providers. It combines parallel quoting, latency testing, parallelized data storage, and automated containerized deployment to save developers running portable workloads 20%+ on compute costs.

๐Ÿš€ Key Features

  • ๐Ÿ”„ Parallel Provisioning: Query all cloud providers simultaneously for optimal pricing
  • ๐Ÿ’ฐ Cost Optimization: Save 20%+ on compute costs through intelligent provider selection
  • ๐ŸŒ Multi-Cloud Support: AWS, GCP, Azure, RunPod, VastAI, Lambda Labs, CoreWeave, TensorDock
  • โšก Real-Time Quoting: Get instant quotes from all providers in parallel
  • ๐Ÿ“Š Analytics & Insights: Comprehensive cost analytics and optimization recommendations
  • ๐Ÿณ Container Orchestration: Automated deployment and management
  • ๐Ÿ“ฆ Dataset Staging: Parallel dataset staging across regions for optimal access
  • ๐Ÿ”’ Secure Credential Management: Encrypted storage of cloud provider credentials

๐Ÿ› ๏ธ Installation

Prerequisites

  • Python 3.9+
  • Cloud provider accounts and API keys
  • Docker (for containerized deployments)

Quick Install

# Clone the repository
git clone https://github.com/terradev/terradev-cli.git
cd terradev-cli

# Install dependencies
pip install -r requirements.txt

# Install CLI
pip install -e .

Verify Installation

terradev --version
terradev --help

๐Ÿ”ง Configuration

Initial Setup

# Configure your cloud providers
terradev configure --provider aws --region us-east-1
terradev configure --provider gcp --region us-central1
terradev configure --provider runpod

# View current configuration
terradev configure

Supported Providers

Provider GPU Types Regions Features
AWS A100, V100, H100 Global Spot instances, on-demand
GCP A100, V100, T4 Global Preemptible instances
Azure A100, V100 Global Spot instances
RunPod RTX4090, A100 Global GPU cloud platform
VastAI A100, RTX4090 Global Marketplace
Lambda Labs A100, RTX6000 Global AI cloud
CoreWeave A100, RTX4090 Global Kubernetes
TensorDock RTX4090, A100 Global GPU marketplace

๐Ÿš€ Quick Start

1. Get Real-Time Quotes

# Get quotes for A100 GPUs across all providers
terradev quote --gpu-type A100 --parallel 8

# Filter by specific providers and regions
terradev quote --gpu-type V100 --providers aws gcp runpod --region us-east-1

2. Provision Instances

# Provision optimal A100 instances
terradev provision --gpu-type A100 --count 2 --max-price 3.0

# Dry run to see what would be provisioned
terradev provision --gpu-type RTX4090 --count 1 --dry-run

3. Manage Instances

# View all instances
terradev status

# Manage specific instance
terradev manage --instance-id aws_i-1234567890abcdef --action status
terradev manage --instance-id runpod_abc123 --action stop

4. Stage Datasets

# Stage dataset across multiple regions
terradev stage --dataset "my-training-data" --target-regions us-east-1 us-west-2 eu-west-1

5. Execute Commands

# Execute commands on instances
terradev execute --instance-id aws_i-1234567890abcdef --command "nvidia-smi"

๐Ÿ“Š Advanced Features

Cost Analytics

# View cost analytics for the last 30 days
terradev analytics --days 30 --format table

# Get JSON output for integration
terradev analytics --days 7 --format json

Automatic Optimization

# Run cost optimization recommendations
terradev optimize

Dataset Management

# Stage with compression
terradev stage --dataset "large-dataset.zip" --compression high --target-regions us-east-1

# Stage to specific cloud regions
terradev stage --dataset "training-images" --target-regions us-east-1 eu-west-1 asia-east-1

๐ŸŒ API Integration

Environment Variables

export TERRADEV_CONFIG_PATH="$HOME/.terradev/config.json"
export TERRADEV_AUTH_PATH="$HOME/.terradev/auth.json"
export TERRADEV_LOG_LEVEL="INFO"

Configuration File

{
  "default_providers": ["aws", "gcp", "runpod"],
  "parallel_queries": 6,
  "max_price_threshold": 10.0,
  "preferred_regions": ["us-east-1", "us-west-2", "eu-west-1"],
  "optimization_settings": {
    "price_weight": 0.4,
    "latency_weight": 0.2,
    "reliability_weight": 0.3,
    "availability_weight": 0.1
  }
}

๐Ÿ”’ Security

Credential Management

Terradev uses encrypted credential storage:

# Credentials are encrypted at rest
ls ~/.terradev/
# config.json  auth.json

# Backup credentials securely
terradev backup --file my-backup.json

# Restore credentials
terradev restore --file my-backup.json

Security Features

  • ๐Ÿ” Encrypted Storage: All credentials encrypted with Fernet
  • ๐Ÿ”‘ Secure Key Management: Automatic key generation and rotation
  • ๐Ÿ›ก๏ธ Permission Control: Role-based access to cloud resources
  • ๐Ÿ“‹ Audit Trail: Complete audit log of all operations
  • ๐Ÿ”„ Token Rotation: Automatic API key rotation support

๐Ÿ“ˆ Performance

Parallel Processing

Terradev achieves 4-6x faster provisioning through parallel processing:

# Sequential approach (slow)
# Provider 1: 2.5s โ†’ Provider 2: 2.3s โ†’ Provider 3: 2.7s = 7.5s total

# Terradev parallel approach (fast)
# Provider 1: 2.5s โ†˜
# Provider 2: 2.3s โ†’ 2.7s total (fastest provider)
# Provider 3: 2.7s โ†—

Cost Savings

Typical cost savings with Terradev:

  • AWS Spot vs On-Demand: 60-70% savings
  • Multi-Cloud Arbitrage: 15-25% savings
  • Regional Optimization: 10-20% savings
  • Dataset Staging: 50-80% egress cost reduction

๐Ÿณ Docker Integration

Containerized Deployment

# Build Docker image
docker build -t terradev-cli .

# Run with mounted credentials
docker run -v ~/.terradev:/root/.terradev terradev-cli quote --gpu-type A100

Kubernetes Deployment

apiVersion: batch/v1
kind: Job
metadata:
  name: terradev-provision
spec:
  template:
    spec:
      containers:
      - name: terradev
        image: terradev-cli:latest
        command: ["terradev", "provision", "--gpu-type", "A100"]
        volumeMounts:
        - name: config
          mountPath: /root/.terradev
      volumes:
      - name: config
        secret:
          secretName: terradev-config

๐Ÿ“Š Monitoring & Analytics

Real-Time Monitoring

# Monitor provisioning progress
terradev status --watch

# Get detailed analytics
terradev analytics --days 30 --detailed

Integration with Grafana

Terradev provides metrics for Grafana dashboards:

  • Cost Metrics: Real-time cost tracking
  • Performance Metrics: Provisioning speed and success rates
  • Utilization Metrics: GPU utilization and availability
  • Savings Metrics: Cost savings and optimization impact

๐Ÿ”ง Troubleshooting

Common Issues

Authentication Errors

# Check credentials
terradev configure

# Re-authenticate
terradev configure --provider aws --api-key YOUR_KEY --secret-key YOUR_SECRET

Provider Connection Issues

# Test provider connectivity
terradev quote --provider aws --gpu-type A100 --dry-run

# Check logs
terradev --verbose status

Instance Provisioning Failures

# Check instance status
terradev manage --instance-id INSTANCE_ID --action status

# View detailed error logs
terradev --verbose provision --gpu-type A100 --dry-run

Debug Mode

# Enable verbose logging
terradev --verbose quote --gpu-type A100

# Debug specific provider
terradev --verbose quote --provider aws --gpu-type A100

๐Ÿค Contributing

Development Setup

# Clone repository
git clone https://github.com/terradev/terradev-cli.git
cd terradev-cli

# Create virtual environment
python -m venv venv
source venv/bin/activate  # Linux/Mac
# or
venv\Scripts\activate  # Windows

# Install development dependencies
pip install -r requirements-dev.txt

# Install in development mode
pip install -e .

Running Tests

# Run all tests
pytest

# Run specific test
pytest tests/test_providers.py

# Run with coverage
pytest --cov=terradev_cli

Adding New Providers

  1. Create provider class in terradev_cli/providers/
  2. Implement BaseProvider interface
  3. Register in ProviderFactory
  4. Add tests
  5. Update documentation

๐Ÿ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.


๐Ÿ†˜ Support

Getting Help

Feature Requests

We welcome feature requests! Please:

  1. Check existing issues
  2. Use the feature request template
  3. Provide detailed requirements
  4. Include use cases and examples

๐Ÿ—บ๏ธ Roadmap

Upcoming Features

  • ๐ŸŒ Web Dashboard: Web-based management interface
  • ๐Ÿ“ฑ Mobile App: iOS and Android applications
  • ๐Ÿ”Œ Plugin System: Extensible plugin architecture
  • ๐Ÿค– AI Optimization: ML-based cost optimization
  • ๐Ÿ“Š Advanced Analytics: Predictive cost analysis
  • ๐Ÿ”— API Gateway: RESTful API for integration
  • ๐Ÿ“ˆ Real-Time Monitoring: Live dashboard and alerts

Provider Expansion

  • Oracle Cloud: OCI GPU instances
  • IBM Cloud: IBM GPU offerings
  • Alibaba Cloud: Alibaba GPU instances
  • DigitalOcean: DO GPU droplets
  • Hetzner Cloud: Hetzner GPU servers

๐ŸŽ‰ Success Stories

Case Studies

Machine Learning Startup

  • Problem: High GPU costs on single cloud provider
  • Solution: Terradev multi-cloud optimization
  • Result: 35% cost reduction with improved performance

Research Institution

  • Problem: Slow sequential provisioning
  • Solution: Parallel provisioning with Terradev
  • Result: 6x faster instance deployment

Enterprise ML Team

  • Problem: Complex multi-cloud management
  • Solution: Unified Terradev interface
  • Result: 50% reduction in management overhead

๐Ÿš€ Get Started Now

Ready to save 20%+ on your compute costs?

# Install Terradev
pip install terradev-cli

# Configure your providers
terradev configure --provider aws --region us-east-1

# Get your first quotes
terradev quote --gpu-type A100

# Start saving!
terradev provision --gpu-type A100 --count 2

๐Ÿš€ Terradev - Parallel provisioning for cross-cloud compute optimization


Built for developers who demand the best performance at the best price.

Project details


Release history Release notifications | RSS feed

This version

1.0.4

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

terradev_cli-1.0.4.tar.gz (7.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

terradev_cli-1.0.4-py3-none-any.whl (6.1 kB view details)

Uploaded Python 3

File details

Details for the file terradev_cli-1.0.4.tar.gz.

File metadata

  • Download URL: terradev_cli-1.0.4.tar.gz
  • Upload date:
  • Size: 7.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.9

File hashes

Hashes for terradev_cli-1.0.4.tar.gz
Algorithm Hash digest
SHA256 22b4f18a6170773c9b4a24438f0bc882065fb4c68d9341a7c30b3b65bce39c12
MD5 967ba801330e59b87f3c39550700e3c9
BLAKE2b-256 0a3549e52d204db17cb46794635f03b58778637783d4ab37c8588c842d887f7b

See more details on using hashes here.

File details

Details for the file terradev_cli-1.0.4-py3-none-any.whl.

File metadata

  • Download URL: terradev_cli-1.0.4-py3-none-any.whl
  • Upload date:
  • Size: 6.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.9

File hashes

Hashes for terradev_cli-1.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 4b898e8767cd2da40a2672310f5a11d80bb85c37367e6843e8eecadb4532be67
MD5 91a0adfc55346dea1be0efa11b5b4aa5
BLAKE2b-256 362f3e60f122e996195938a10ef9ad5b4746dd37643c0d483351396b979dc6fc

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page