Running composer install
on a production server via a bash script is failing at post-install-cmd
php artisan optimize
with the error There are no commands defined in the "jwt" namespace
.
To try to resolve the issue I added the following commands before php artisan optimize
"php artisan clear-compiled",
"php artisan cache:clear",
"php artisan config:clear",
"php artisan config:cache",
Running composer install
locally works fine. I can run the commands through a script locally without a problem.
The failure is happening while running composer install
through a script on the production server. If I log onto the server and run the commands manually I do not generate the error.
Not sure how to debug, any ideas?