laravel/framework
schedule:work run artisan relative to current working dir
Aperta
#56.390 aperta il 23 lug 2025
help wanted
Metriche repository
- Star
- (34.869 stelle)
- Metriche merge PR
- (Merge medio 1g 22h) (129 PR mergiate in 30 g)
Descrizione
Laravel Version
12.19.3
PHP Version
8.4.10
Database Driver & Version
No response
Description
Hello,
The command artisan schedule:work run artisan schedule:run every minutes, but this works only if we are in the same directory than artisan
Steps To Reproduce
- Create laravel in
/home/laravel. - Go in
/home/laravelrunphp84 artisan schedule:workit WORKS - Go in
/runphp84 /home/laravel/artisan schedule:workit DOESN'T WORKS
It raise
...
Could not open input file: artisan
Could not open input file: artisan
Could not open input file: artisan
Could not open input file: artisan
...
Example
[root@server /]$ /bin/php84 /home/laravel/artisan schedule:work
Could not open input file: artisan
^C
[root@server ~]$ cd /home/laravel
[root@server ~]$ /bin/php84 /home/laravel/artisan schedule:work
2025-07-23 20:30:00 Running [TASK #1] 395.67ms DONE