Skip to content

Quickstart ​

This page walks you from a fresh install to a working Postgres instance in under a minute. It assumes you've already installed vibepg (Installation) and have Docker running (vibepg doctor to confirm).

Zero to a query in 60 seconds ​

bash
# Create a persistent instance named "demo"
vibepg new demo

# Run a query
vibepg exec demo "select now();"

# Drop into psql for ad-hoc work
vibepg psql demo

That's it. vibepg new pulls the postgres:16 image (the first time), starts a container, picks a free port, generates a strong password, stores it in your OS keychain, and waits until the database is ready.

Persistent vs ephemeral ​

By default instances are persistent — they back onto a Docker volume that survives vibepg down, vibepg up, and even vibepg rm (unless you pass --with-volume).

For throwaway databases — running a test suite, exploring a query plan, scratch-pad work — use --ephemeral:

bash
vibepg new scratch --ephemeral
# ... do stuff ...
vibepg rm scratch       # data is gone, no volume to clean up

See Persistence & Data for the full story.

Loading a schema ​

bash
vibepg run demo schema.sql

run accepts multiple files and executes them in order. Wrap them in a single transaction with --transaction:

bash
vibepg run demo 0-schema.sql 1-fixtures.sql 2-indexes.sql --transaction

Importing CSV ​

bash
vibepg import demo users ./users.csv

For TSV or custom schemas:

bash
vibepg import demo events events.tsv \
  --schema analytics \
  --delimiter "\t" \
  --columns id,event_type,created_at

Listing and inspecting instances ​

bash
vibepg ls                # all instances + Docker state
vibepg status demo       # health and metadata for one
vibepg status demo --json | jq .
vibepg url demo          # postgres:// URL with embedded password

Cleanup ​

bash
vibepg down demo               # stop the container, keep everything
vibepg up demo                 # start it again
vibepg rm demo                 # remove container + registry entry; volume preserved
vibepg rm demo --with-volume   # remove everything, data is gone

Next steps ​

Released under the MIT License.