db:reset

Drop all tables and re-apply migrations from scratch.


Usage

splent db:reset [-y]

Examples

Full reset with confirmation prompt:

splent db:reset

Skip confirmation:

splent db:reset -y

Options

Option Description
-y, --yes Skip the confirmation prompt.

Description

Performs a full database reset in this order:

  1. Drops ALL tables — including data tables, alembic_<feature> version tables, and splent_migrations. Uses SET FOREIGN_KEY_CHECKS = 0 to handle FK constraints.
  2. Recreates the splent_migrations tracking table.
  3. Clears uploaded files.
  4. Re-applies all existing feature migrations via alembic upgrade head, respecting UVL dependency order (e.g., auth before profile). Features without a models module (e.g. config-only features like admin or phpmyadmin) are silently skipped.

This command destroys all data in the database. Feature migration files are NOT deleted — only the database is wiped and rebuilt.


Migration order

Migrations are applied in dependency order based on UVL constraints, ensuring that tables referenced by foreign keys are created first.


Requirements

  • SPLENT_APP must be set.
  • The database must be reachable.

See also

  • db:migrate — Generate and apply new migrations
  • db:upgrade — Apply pending migrations
  • db:status — Show current migration status
  • db:seed — Populate the database after reset

Back to top

splent. Distributed by an LGPL license v3. Contact us: drorganvidez@us.es