Project Reference
Use this page when you need a command or config convention. For a first project, start with the Quickstart.
Config Filename and Export
Use cloud.config.ts in the project root. The CLI and Nuxt module also recognize
the legacy cloudconfig.config.ts name. If both exist, cloud.config.ts takes
precedence; keep one config file to avoid editing the unused one.
New projects use a named export:
import { defineBackend, model, t } from '@cloudconfig/core'
export const config = defineBackend({
models: { post: model({ title: t.text().required() }) },
})
export default defineBackend({ ... }) is also supported. Choose either style;
you do not need to export both. With a default export, use
import type config from './cloud.config' for the typed client examples below.
Common Commands
Run these commands from the project root. The db:* and doctor scripts are
included in generated projects.
| Task | Command |
|---|---|
| Generate a migration after a model change | pnpm db:generate |
| Apply local migrations | pnpm db:migrate |
| Check local migration status | pnpm db:status |
| Check the config and local setup | pnpm doctor |
| Inspect sign-in settings | pnpm exec cloudconfig auth status |
| Inspect integration settings | pnpm exec cloudconfig connect status |
| Inspect the configured remote database | pnpm exec cloudconfig db status --remote |
| Preview deployment for the selected host | pnpm exec cloudconfig deploy --dry-run |
| Deploy the application | pnpm exec cloudconfig deploy |
For all options, run pnpm exec cloudconfig --help or add --help after a
command, such as pnpm exec cloudconfig deploy --help.