Quick Start
This guide walks you through deploying your first application with Jiji.
1. Create Configuration
Initialize Jiji in your project:
jiji initEdit .jiji/deploy.yml:
project: myapp
builder:
engine: docker
local: true
registry:
type: local
ssh:
user: deploy
servers:
web1:
host: server1.example.com
services:
web:
build:
context: .
dockerfile: Dockerfile
hosts:
- web1
proxy:
app_port: 3000
host: myapp.example.com
ssl: true
healthcheck:
path: /health
interval: 10s
timeout: 5s2. Initialize Servers
Set up your servers with the required components:
jiji server init3. Setup Registry
Configure your container registry:
jiji registry setup4. Build and Deploy
Deploy your application:
# Build and deploy in one command
jiji deploy --build
# Or separately
jiji build
jiji deploy5. Verify Deployment
Check your services:
# View logs
jiji services logs
# Check service status on servers
jiji server exec "docker ps"What Happens During Deployment
- Build Phase - Container image is built locally or remotely
- Push Phase - Image is pushed to the configured registry
- Deploy Phase:
- Old container keeps running
- New container starts alongside
- Health checks run until ready
- Proxy routes traffic to new container
- Old container is stopped and removed
- Cleanup - Old images are pruned (keeping recent versions)
Environment-Specific Deployments
Create environment-specific configs:
# .jiji/deploy.yml - base config
# .jiji/deploy.staging.yml - staging overrides
# .jiji/deploy.production.yml - production overridesDeploy to a specific environment:
jiji deploy -e staging
jiji deploy -e productionNext Steps
- Configuration Reference - Full configuration options
- Deployment Guide - Advanced deployment strategies
- Network Reference - Private networking setup
Last updated on