We have a Laravel deployment website set up under deploy.mysite.com which handles deployments for a multitude of other websites. One other website I’m trying to deploy which is also a Laravel site resides under site2.myothersite.com. Both are on the same server. Deploy calls a script on site2, this depl…
Tag: laravel-artisan
laravel 5.5 schedule:run cron job not working in cpanel
I’m have a laravel5.5 project up on shared hosting and trying to run cron job to execute the command “schedule:run” but it just won’t execute I think I’m writing the command wrong: where prototype in the name of my laravel project. the command works in this directory using ssh. p…
Migrations in Laravel 5.5: Cannot declare class because the name is already in use
While running a migration in Laravel I got an error: PHP Fatal error: Cannot declare class UpdateEnquiriesTable, because the name is already in use in /var/www/project/database/migrations/2018_01_17_160335_update_enquiries_table.php on line 33 Having done a bit of research, I see that each migration file need…
Laravel 5 command – Mandatory options
I am trying to write a laravel command but I can’t have the options to be mandatory. I do understand that the concept of option is being “optional” but I’d like to have a command in which it is clear which input you are inserting and in no particular order. i.e. I would like to achieve…
How does Laravel Artisan created php files with properly formatted lines
This is just a general question, how does Laravel Artisan able to create proper .php file e.g. make:controller with the correct formatting and line breaks? Is there a good PHP script which can help one develop similar php codes. Thanks Answer PHP files are just text files, you can easily create them with any …
migrating a specific table in laravel
using command php artisan migrate migrates all the tables. but i have employees table that i migrated along with other tables. but it is not migrated (i cannot see it in phpmyadmin). now when i again use php artisan migrate command it displays nothing to migrate. How can i migrate that specific employees tabl…
Xdebug laravel artisan commands
I regularly use xdebug to debug applications, I’ve built a laravel application that takes an upload of a csv inserts the data to the database and the ids to a job queue. I’ve written an artisan …
Execute Laravel/Symfony/Artisan Command in Background
I need to execute a Laravel long running process in the background for consuming the Twitter Streaming API. Effectively the php artisan CLI command I need to run is nohup php artisan startStreaming &…
Laravel “artisan make:observer” fails
I am trying to generate a provider using Artisan as described on the documentation page [1] by running: php artisan make:observer AdServiceProvider However I get the following error: […
Laravel seeder gives error. Class not found
I’m a newbie in Laravel and and I’m teaching myself how to authenticate from a login table. I have migrated and created the table. Now, I’m trying to seed the data into the login table, but the …