Deploying Applications
Learn how to deploy your applications to Uncloud, whether you're building from source or using pre-built images.
Quick Reference
Choose the deployment approach that fits your workflow:
The Happy Path: uc deploy
For most users, uc deploy is all you need. It handles building and deploying in a single command.
uc deploy
When to use this:
- You have a
compose.yamlwith abuildsection - You want the simplest workflow
- You're deploying from your development machine
What happens:
- Builds Docker images locally (if
buildsection exists) - Pushes images to your cluster machines
- Creates or updates containers with zero downtime
Build and Deploy Separately
Split building and deploying into two steps for more control.
# Step 1: Build images
uc build
# Step 2: Deploy to cluster
uc deploy --no-build
When to use this:
- You want to test builds without deploying
- You're building once and deploying multiple times
- You're working with CI/CD pipelines
Deploy Pre-built Images
Skip building entirely and deploy images from Docker Hub or other registries.
services:
web:
image: nginx:alpine
uc deploy
When to use this:
- You're using public images
- Your images are built externally
- You're deploying third-party applications
Common Deployment Workflows
Development Workflow
# Make code changes
vim src/app.py
# Deploy with automatic rebuild
uc deploy
# Your changes are live with zero downtime
Multi-service Application
# Deploy all services
uc deploy
# Deploy specific services only
uc deploy frontend api
Production Deployment
# Preview changes before deploying
uc deploy
# Review the deployment plan
# Confirm to proceed
Deployment Flow
Here's what happens when you run uc deploy:
Your Code
↓
Local Build (if Dockerfile present)
↓
Push Images to Cluster
↓
Create New Containers
↓
Zero-downtime Switch
↓
Remove Old Containers
Choose Your Guide
Select the guide that matches your use case:
- Deploy from Dockerfile - Build and deploy a custom application
- Multi-service Deployment - Deploy applications with multiple services
- Deploy Pre-built Images - Use images from registries
- Updating Services - Update running applications
Need More Control?
Check out the Building Images guides to learn when and how to use uc build separately.