Closed mehrenreich closed 1 year ago
OK, USAGE says:
ORM Version: seed:run [-c <...>] [--dry] [-d <...>] [-C <...>] [<table>]
So, when adding the table
name (as in SQL), I get:
masonite-orm seed:run -C config.py -d seeds tenants
ValueError
Could not find the seeds.tenants_table_seeder.TenantsTableSeeder seeder file
When adding the model
name, it's:
masonite-orm seed:run -C config.py -d seeds Tenant
ConfigurationNotFound
ORM configuration file has not been found in config.database.
Got it, it's working now.
Turned out that I need to explicitly set the DB_CONFIG_PATH
var in order to make it work:
DB_CONFIG_PATH=db/config.py masonite-orm seed:run -C db/config.py -d db/seeds Tenant
The -C
option seems to be ignored.
Describe the bug
When trying to execute a database seeder, I'm running into this error:
The seeder file:
The seeder file, as well as the files for model and migrations, have been created using:
The migration went well, so the database config (and connection) is good.
My workplace looks like:
Database config:
To Reproduce Steps to reproduce the behavior:
Expected behaviour One new
Tenant
model with the nametest
written to the database.What database are you using?