php 管理员ctl worker.log错误:无法打开输入文件:/用户/../技工

bn31dyow  于 2022-12-28  发布在  PHP
关注(0)|答案(1)|浏览(107)

Laravel工作器无法执行命令工匠队列:工作,但状态显示工作器正在运行,我知道监管命令中的命令有问题,但无法解决。

My supervisord.conf file:
    [program:laravel-worker]
    process_name=%(program_name)s\_%(process_num)02d

    command=/opt/homebrew/bin/php /Users/ricky/Documents/Project/Blog/ artisan queue:work database --sleep=3 --tries=3 --max-time=3600
    autostart=true
    autorestart=true
    stopasgroup=true
    killasgroup=true
    numprocs=2
    redirect_stderr=true
    stdout_logfile=/Users/ricky/Documents/Project/Blog/worker.log
    stopwaitsecs=3600
    startsecs = 0
    stopasgroup=true
    stopsignal=QUIT

    supervisor status
    laravel-worker:laravel-worker_00   RUNNING   pid 98925, uptime 0:00:00
    laravel-worker:laravel-worker_01   RUNNING   pid 98924, uptime 0:00:00
    
    worker.log file shows error
    Could not open input file: /Users/ricky/Documents/Project/Blog/artisan..
sqxo8psd

sqxo8psd1#

您的主管无法找到工匠

command=/opt/homebrew/bin/php /Users/ricky/Documents/Project/Blog/artisan queue:work database --sleep=3 --tries=3 --max-time=3600

你刚刚有了一个额外的空间,你可以直接在终端中运行命令来测试它,看看它是否运行,然后编辑文件,所以在终端中运行:

/opt/homebrew/bin/php /Users/ricky/Documents/Project/Blog/artisan queue:work database --sleep=3 --tries=3 --max-time=3600

确保使用文件夹的绝对路径。

相关问题