You have two options that will help you out. You can specify the environment that the console will run in with the --env
flag, and use --no-debug
to disable debug mode.
php app/console --env=staging your:console:command
or php app/console --env=prod your:console:command
should do what you're looking for (the console runs in the dev
environment with debug on by default).
You can look at the code of the app/console
file for more info.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…