Minimal with Database

Single component with Postgres and a health check.

What this demonstrates

  • The `requires` array shorthand — `[postgres]` expands to `[{type: postgres}]`
  • Providers auto-provision required resources and inject connection details
  • The `health` shorthand — a path string expands to `{path: /health}`

When to use this: Most web apps need a database — this is the typical starting point.

Requires Health
minimal-with-db.yaml View on GitHub
# yaml-language-server: $schema=../schema/launchfile.schema.json
version: launch/v1
name: my-app
runtime: node
requires: [postgres]
commands:
  start: "node server.js"

Key lines explained

requires: [postgres]
Shorthand for [{type: postgres}]. The provider creates the DB and injects $url, $host, etc.
health: /health
Shorthand for {path: /health}. Providers poll this endpoint to confirm readiness.
esc
Type to search the docs