Skip to content

Real-World Use Cases & Examples

Discover how developers use The Stratus to streamline their deployment workflows. From static websites to enterprise applications, learn best practices and proven configurations.

Static Website Hosting

Deploy your HTML, CSS, and JavaScript websites directly to AWS S3 or DigitalOcean Spaces with CloudFront/CDN integration.

Perfect For:

  • Personal portfolios and blogs
  • Documentation sites
  • Landing pages
  • React, Vue, or Angular SPAs

Example Configuration

{
  "version": "1.0",
  "activeProfile": "production",
  "profiles": {
    "production": {
      "name": "production",
      "provider": "aws-s3",
      "config": {
        "accessKeyId": "AKIA...",
        "secretAccessKey": "********",
        "region": "us-east-1",
        "bucket": "my-portfolio.com",
        "acl": "public-read",
        "cacheControl": "max-age=31536000, immutable"
      },
      "uploadOnSave": true,
      "watchPatterns": ["dist/**/*"],
      "ignorePatterns": [
        "**/node_modules/**",
        "**/.git/**",
        "**/src/**",
        "**/*.config.js"
      ]
    }
  }
}

Workflow Tips:

  1. Build your static site: npm run build
  2. The Stratus automatically syncs the dist/ folder
  3. Changes go live instantly
  4. Set aggressive cache headers for performance
Pro Tip: Use cacheControl: "max-age=31536000, immutable" for static assets and enable CloudFront invalidation for instant cache updates.

Next.js / React Applications

Deploy your Next.js static exports or React builds directly from VS Code.

Next.js Static Export

{
  "version": "1.0",
  "activeProfile": "production",
  "profiles": {
    "production": {
      "name": "production",
      "provider": "aws-s3",
      "config": {
        "bucket": "my-nextjs-app.com",
        "region": "us-east-1",
        "acl": "public-read",
        "prefix": "",
        "cacheControl": "public, max-age=3600"
      },
      "uploadOnSave": false,
      "watchPatterns": ["out/**/*"],
      "ignorePatterns": [
        "**/node_modules/**",
        "**/.next/**",
        "**/src/**"
      ]
    }
  }
}

Build & Deploy Process:

# 1. Configure Next.js for static export (next.config.js)
module.exports = {
  output: 'export',
  trailingSlash: true
}

# 2. Build your application
npm run build

# 3. Stratus syncs the 'out/' folder automatically
# 4. Your site is live!
Build Integration: Consider adding a VS Code task that runs npm run build before triggering Stratus: Sync Now.

Traditional Web Hosting (FTP/SFTP)

Deploy to classic shared hosting, cPanel, or VPS servers via FTP or SFTP.

Shared Hosting Example (cPanel)

{
  "version": "1.0",
  "activeProfile": "production",
  "profiles": {
    "production": {
      "name": "production",
      "provider": "sftp",
      "config": {
        "host": "ftp.yourhosting.com",
        "port": 22,
        "username": "username",
        "password": "********",
        "prefix": "public_html/myproject/"
      },
      "uploadOnSave": true,
      "ignorePatterns": [
        "**/node_modules/**",
        "**/.git/**",
        "**/.env"
      ]
    }
  }
}

VPS with SSH Key Authentication

{
  "version": "1.0",
  "activeProfile": "production",
  "profiles": {
    "production": {
      "name": "production",
      "provider": "sftp",
      "config": {
        "host": "123.45.67.89",
        "port": 22,
        "username": "deploy",
        "privateKey": "/Users/you/.ssh/id_rsa",
        "prefix": "/var/www/html/"
      },
      "uploadOnSave": true,
      "compareBy": "md5"
    }
  }
}
Security: Always use SFTP (port 22) instead of FTP (port 21) for encrypted connections. Prefer SSH key authentication over passwords.

Multi-Environment Deployment

Manage development, staging, and production environments with profile switching.

Multi-Profile Configuration

{
  "version": "1.0",
  "activeProfile": "staging",
  "profiles": {
    "development": {
      "name": "development",
      "provider": "aws-s3",
      "config": {
        "bucket": "dev-myapp.com",
        "region": "us-east-1",
        "acl": "private"
      },
      "uploadOnSave": true
    },
    "staging": {
      "name": "staging",
      "provider": "aws-s3",
      "config": {
        "bucket": "staging-myapp.com",
        "region": "us-east-1",
        "acl": "public-read"
      },
      "uploadOnSave": true,
      "compareBy": "md5"
    },
    "production": {
      "name": "production",
      "provider": "aws-s3",
      "config": {
        "bucket": "myapp.com",
        "region": "us-east-1",
        "acl": "public-read",
        "cacheControl": "max-age=31536000"
      },
      "uploadOnSave": false,
      "compareBy": "md5"
    }
  }
}

Workflow:

  1. Work in development profile with auto-sync enabled
  2. Switch to staging for QA testing: Stratus: Select Profile → staging
  3. Deploy to production manually: Stratus: Select Profile → production then Stratus: Sync Now
Pro Tip: Disable uploadOnSave for production to prevent accidental deployments. Use manual sync for production releases.

Media & Asset Management

Sync design files, images, and media assets to cloud storage for team collaboration.

Example: Design Team Workflow

{
  "version": "1.0",
  "activeProfile": "assets",
  "profiles": {
    "assets": {
      "name": "assets",
      "provider": "gcs",
      "config": {
        "projectId": "design-team-assets",
        "keyFilename": "/path/to/key.json",
        "bucket": "team-design-files",
        "storageClass": "STANDARD"
      },
      "uploadOnSave": true,
      "watchPatterns": [
        "assets/**/*.{png,jpg,svg,gif}",
        "fonts/**/*.{woff,woff2,ttf}",
        "videos/**/*.mp4"
      ],
      "ignorePatterns": [
        "**/*.psd",
        "**/*.ai",
        "**/*.sketch"
      ]
    }
  }
}

Use Cases:

  • Automatic CDN sync for website assets
  • Team collaboration on design files
  • Version control for media libraries
  • Backup large files to cloud storage

WordPress Plugin/Theme Development

Develop locally and sync your WordPress plugins or themes directly to a staging server.

Example Configuration

{
  "version": "1.0",
  "activeProfile": "wp-staging",
  "profiles": {
    "wp-staging": {
      "name": "wp-staging",
      "provider": "sftp",
      "config": {
        "host": "staging.mysite.com",
        "port": 22,
        "username": "wpuser",
        "privateKey": "~/.ssh/id_rsa",
        "prefix": "wp-content/plugins/my-plugin/"
      },
      "uploadOnSave": true,
      "ignorePatterns": [
        "**/node_modules/**",
        "**/.git/**",
        "**/tests/**",
        "**/*.md"
      ]
    }
  }
}

Development Workflow:

  1. Edit PHP/CSS/JS files locally in VS Code
  2. Save changes → Automatically synced to staging
  3. Test changes on staging site immediately
  4. No manual FTP uploads needed!

API Documentation & Static Site Generators

Deploy documentation sites generated by Docusaurus, VuePress, Jekyll, Hugo, etc.

Docusaurus Example

{
  "version": "1.0",
  "activeProfile": "docs",
  "profiles": {
    "docs": {
      "name": "docs",
      "provider": "do-spaces",
      "config": {
        "accessKeyId": "DO00...",
        "secretAccessKey": "********",
        "region": "nyc3",
        "bucket": "api-documentation",
        "acl": "public-read",
        "endpoint": "https://nyc3.digitaloceanspaces.com"
      },
      "uploadOnSave": false,
      "watchPatterns": ["build/**/*"],
      "ignorePatterns": [
        "**/node_modules/**",
        "**/src/**",
        "**/.docusaurus/**"
      ]
    }
  }
}

Build & Deploy:

# Build documentation
npm run build

# Manually sync (or trigger via task)
Cmd+Shift+P → Stratus: Sync Now

# Documentation is live at:
# https://api-documentation.nyc3.digitaloceanspaces.com

Automated Project Backups

Automatically backup your codebase to cloud storage as you work.

Example: Daily Backup Configuration

{
  "version": "1.0",
  "activeProfile": "backup",
  "profiles": {
    "backup": {
      "name": "backup",
      "provider": "gcs",
      "config": {
        "projectId": "my-backups",
        "keyFilename": "/path/to/key.json",
        "bucket": "code-backups",
        "prefix": "project-name/",
        "storageClass": "NEARLINE"
      },
      "uploadOnSave": false,
      "compareBy": "md5",
      "ignorePatterns": [
        "**/node_modules/**",
        "**/.git/**",
        "**/dist/**",
        "**/*.log"
      ]
    }
  }
}

Usage:

  • Run Stratus: Sync Now at end of day
  • Use NEARLINE storage class for cost savings
  • MD5 comparison prevents duplicate backups
  • Version history maintained by cloud provider

Microservices & Serverless Functions

Deploy serverless functions and microservices to cloud providers.

AWS Lambda Example

{
  "version": "1.0",
  "activeProfile": "lambda",
  "profiles": {
    "lambda": {
      "name": "lambda",
      "provider": "aws-s3",
      "config": {
        "bucket": "lambda-deployments",
        "region": "us-east-1",
        "prefix": "functions/"
      },
      "uploadOnSave": false,
      "watchPatterns": [
        "dist/**/*.zip"
      ]
    }
  }
}

Deployment Process:

# 1. Build your Lambda function
npm run build

# 2. Package as ZIP
npm run package

# 3. Sync to S3
Stratus: Sync Now

# 4. Update Lambda from S3 (via AWS CLI or console)

Best Practices

Security

  • Never commit .stratus/config.json to Git
  • Use environment-specific credentials
  • Prefer SSH keys over passwords for SFTP
  • Use IAM roles with least privilege access
  • Enable encryption at rest for sensitive data

Performance

  • Use MD5 comparison to avoid re-uploading unchanged files
  • Enable parallel uploads (Pro: up to 10 concurrent)
  • Set appropriate cache headers for static assets
  • Choose cloud regions closest to your users
  • Use CDN for global content delivery

Workflow

  • Enable uploadOnSave for dev environments
  • Disable uploadOnSave for production (manual only)
  • Use watch patterns to sync only built files
  • Ignore source files, node_modules, and logs
  • Test deployments in staging before production

Cost Optimization

  • Use appropriate storage classes (STANDARD vs NEARLINE)
  • Enable lifecycle policies to archive old files
  • Compress assets before upload (gzip, Brotli)
  • Monitor bandwidth usage and set alerts
  • Delete old backups and temporary files

Advanced Patterns

Pattern 1: Split Asset Uploads

Separate HTML/CSS from images to optimize cache invalidation:

{
  "profiles": {
    "static-files": {
      "provider": "aws-s3",
      "config": { "bucket": "mysite.com", "prefix": "static/" },
      "watchPatterns": ["dist/**/*.{html,css,js}"],
      "cacheControl": "max-age=3600"
    },
    "assets": {
      "provider": "aws-s3",
      "config": { "bucket": "mysite.com", "prefix": "assets/" },
      "watchPatterns": ["dist/**/*.{png,jpg,svg}"],
      "cacheControl": "max-age=31536000, immutable"
    }
  }
}

Pattern 2: Atomic Deployments

Deploy to versioned directories for zero-downtime releases:

{
  "provider": "aws-s3",
  "config": {
    "bucket": "mysite.com",
    "prefix": "releases/v1.2.3/"
  }
}

Pattern 3: Hybrid Cloud Strategy

Use multiple providers for redundancy:

{
  "profiles": {
    "primary": {
      "provider": "aws-s3",
      "config": { "bucket": "primary-cdn" }
    },
    "backup": {
      "provider": "gcs",
      "config": { "bucket": "backup-storage" }
    }
  }
}

Need More Examples?

Explore our GitHub repository for more configuration examples and community contributions:

Ready to deploy? Start with one of these examples and customize it for your workflow!