Compose


Jerboa compose is a small, project-local stack format implemented in internal/compose/.

File Format

version: "1"

services:
  api:
    image: api:latest
    memory: 256M
    cpus: 1
    depends_on: [db]
    networks: [app]
    ip: 10.100.0.10
    environment:
      - PORT=8080
    ports:
      - "8080:8080"
    volumes:
      - data:/var/data
    health_check: "http:8080:/healthz"
    restart: "on-failure:5"

networks:
  app:
    driver: bridge
    subnet: 10.100.0.0/24

volumes:
  data:
    size: 1G

What The Parser Enforces

Current Runtime Semantics

Commands

jerboa compose up stack.yaml
jerboa compose ps stack.yaml
jerboa compose logs stack.yaml api
jerboa compose down stack.yaml --volumes

Current limits:

Ordering

Startup order is computed with topological sort from depends_on.

Services are removed in alphabetical order. Startup dependencies do not currently determine shutdown ordering.

Upgrading Existing Stacks

Before upgrading from 0.51.1, stop existing stacks with the old CLI. Version 0.51.2 does not automatically assign a legacy .jerboa-compose-state.json file to a project because that file cannot identify which compose definition owns it.

If you have already upgraded, inspect the service VM IDs recorded in the legacy file and stop and remove those VMs explicitly. Inspect its recorded networks and volumes before removing any resources you no longer need. Then deploy with compose up to create the new state. Preserve volumes that hold data you want to keep.