Migration Configuration
Control how Moose handles database migrations and schema changes.
moose.config.toml
[migration_config]# Operations to ignore during migration plan generation and drift detection# ignore_operations = ["ModifyTableTtl", "ModifyColumnTtl", "ModifyPartitionBy", "IgnoreStringLowCardinalityDifferences"] # Allow destructive changes in production without a reviewed plan.yaml (default: false)# prod_auto_allow_destructive = false| Key | Env Variable | Default | Description |
|---|---|---|---|
ignore_operations | MOOSE_MIGRATION_CONFIG__IGNORE_OPERATIONS | [] | List of migration operations to ignore during plan generation. |
prod_auto_allow_destructive | MOOSE_MIGRATION_CONFIG__PROD_AUTO_ALLOW_DESTRUCTIVE | false | When false, moose prod refuses to start if the computed infrastructure diff contains destructive operations (table drops, column drops, view removals, table recreates) and no plan.yaml is present. Set to true to allow unplanned destructive changes in production. |
Available Operations
| Operation | Description |
|---|---|
ModifyTableTtl | Ignore changes to table-level TTL settings. |
ModifyColumnTtl | Ignore changes to column-level TTL settings. |
ModifyPartitionBy | Ignore changes to partition key expressions. |
IgnoreStringLowCardinalityDifferences | Treat LowCardinality(String) and String as equivalent during schema comparison. Useful when ClickHouse automatically applies LowCardinality to string columns. |