We have moved our forum to GitHub Discussions. For questions about Phalcon v3/v4/v5 you can visit here and for Phalcon v6 here.

Use phalcon-devtools without a config

Hey there!

I'm trying to create a controller from the devtools. I don't use a config (I do that in my index.php). But I get an error with this command:

$ phalcon controller test app/frontend/controllers/

Can I create controllers (and later do migrations) without a config.php|ini?

Thanks for your attention.

No.

For run commands need:

  1. '.phalcon' directory
  2. 'config.php' file

But is possible create controller with this:

phalcon controller MyController --output=.

For migrations is neccesary config.php



14.4k

Thanks alot!

Do I only have to define my database when I will do my migration? Or do I have to tell the devtools where my models are? I got a module system (frontend, backend).

Use:

phalcon migration --action=generate --config=path/to/config

For help use:

phalcon migration