Skip to content

Quick Start

Get a headless CMS running in 5 minutes.

  • Rust 1.91+ (rustup)
  • AWS account with CLI configured — see AWS Setup for step-by-step instructions
  • Your developer IAM user needs rds:CreateDBInstance, rds:DeleteDBInstance, and rds:DescribeDBInstances permissions
Terminal window
git clone https://github.com/smattera/chukfi-core
cd chukfi-core

Each developer gets their own RDS PostgreSQL instance. Run this once — it takes ~10 minutes the first time.

Terminal window
chukfi db create --name my-chukfi-dev --region us-east-1

When it finishes, you’ll see a DATABASE_URL like:

postgres://chukfi:<password>@my-chukfi-dev.abcdef.us-east-1.rds.amazonaws.com:5432/chukfi
Terminal window
# Copy the standard config template
cp chukfi-bin/templates/standard.config.json chukfi.config.json
# Create .env with the DATABASE_URL from step 1 + a random JWT secret
cat > .env << EOF
DATABASE_URL=postgres://chukfi:<password>@your-instance.region.rds.amazonaws.com:5432/chukfi
CHUKFI_JWT_SECRET=$(openssl rand -hex 32)
CHUKFI_DEV_MODE=true
EOF
Terminal window
cargo build --release -p chukfi-bin
./target/release/chukfi serve

Server is live at http://localhost:8080.

Terminal window
./target/release/chukfi seed

Seeds demo pages and media assets for every content type defined in your config. Navigation groups ship with the schema migrations and are created automatically on first run. Admin users are created lazily by chukfi token <email>.

Dev mode auto-creates users on first login. To get a JWT without the browser:

Terminal window
./target/release/chukfi token you@example.com

Use it in headers: Authorization: Bearer <token>

Terminal window
TOKEN=$(./target/release/chukfi token you@example.com)
curl -H "Authorization: Bearer $TOKEN" http://localhost:8080/api/admin/config

The embedded admin dashboard is bundled in the binary — just open http://localhost:8080 in your browser and sign in. No separate build step.

For the optional Dioxus admin UI:

Terminal window
cd chukfi-admin-ui
trunk serve --open # Opens admin UI at http://localhost:8081 (API runs at http://localhost:8080)
Terminal window
cargo install chukfi-bin
chukfi serve

The binary auto-runs migrations on startup (no sqlx migrate run needed) and serves the embedded admin dashboard at http://localhost:8080. To scaffold a config, run chukfi init (writes chukfi.config.json + .env.example).

Edit chukfi.config.json to:

  • Add content types — blog posts, products, events
  • Change auth — wire up Entra ID, Cognito, or SES magic links
  • Configure the admin — name, color, custom components
  • Set S3 media storage — switch from local filesystem to AWS

Restart the server after changing config.

Command What it does
chukfi db create --name <id> Create a per-dev AWS RDS instance
chukfi db list List your RDS instances
chukfi db destroy --id <id> --yes Destroy an RDS instance
chukfi serve Start the API server (default command)
chukfi seed Seed demo data (pages, media, users)
chukfi token <email> Generate a JWT for local dev
chukfi content create --type pages --title "Hello" Create content via CLI
chukfi content list --type pages List content entries
chukfi media upload --path ./photo.jpg Upload a file
chukfi media list List media assets
chukfi codegen Generate TypeScript types from schema

When you’re done working on a project:

Terminal window
chukfi db destroy --id my-chukfi-dev --yes

This deletes the RDS instance so you’re not paying for idle compute.

  • Optional Dioxus admin UI — the embedded vanilla-JS dashboard is the default; the Dioxus UI in chukfi-admin-ui/ is an optional richer interface built separately with trunk build.