<legend id='V1y40'><style id='V1y40'><dir id='V1y40'><q id='V1y40'></q></dir></style></legend>

      <tfoot id='V1y40'></tfoot>

        <small id='V1y40'></small><noframes id='V1y40'>

        • <bdo id='V1y40'></bdo><ul id='V1y40'></ul>
        <i id='V1y40'><tr id='V1y40'><dt id='V1y40'><q id='V1y40'><span id='V1y40'><b id='V1y40'><form id='V1y40'><ins id='V1y40'></ins><ul id='V1y40'></ul><sub id='V1y40'></sub></form><legend id='V1y40'></legend><bdo id='V1y40'><pre id='V1y40'><center id='V1y40'></center></pre></bdo></b><th id='V1y40'></th></span></q></dt></tr></i><div id='V1y40'><tfoot id='V1y40'></tfoot><dl id='V1y40'><fieldset id='V1y40'></fieldset></dl></div>
      1. 无法通过 cron 作业使用自定义 Laravel Artisan 命令

        Custom Laravel Artisan command not available through cron job(无法通过 cron 作业使用自定义 Laravel Artisan 命令)
      2. <small id='zBaFz'></small><noframes id='zBaFz'>

        • <bdo id='zBaFz'></bdo><ul id='zBaFz'></ul>
          <tfoot id='zBaFz'></tfoot>
          <legend id='zBaFz'><style id='zBaFz'><dir id='zBaFz'><q id='zBaFz'></q></dir></style></legend>

        • <i id='zBaFz'><tr id='zBaFz'><dt id='zBaFz'><q id='zBaFz'><span id='zBaFz'><b id='zBaFz'><form id='zBaFz'><ins id='zBaFz'></ins><ul id='zBaFz'></ul><sub id='zBaFz'></sub></form><legend id='zBaFz'></legend><bdo id='zBaFz'><pre id='zBaFz'><center id='zBaFz'></center></pre></bdo></b><th id='zBaFz'></th></span></q></dt></tr></i><div id='zBaFz'><tfoot id='zBaFz'></tfoot><dl id='zBaFz'><fieldset id='zBaFz'></fieldset></dl></div>

                    <tbody id='zBaFz'></tbody>
                  本文介绍了无法通过 cron 作业使用自定义 Laravel Artisan 命令的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  当我通过 SSH 连接时,我有自定义的 Artisan 命令在本地以及我的生产服务器上运行,但对任何 cron 作业都不可用.我什至尝试以运行 cron 作业的用户身份运行它,并且在我的控制台上运行良好.

                  I have custom Artisan commands that run locally as well as on my production server when I am SSH'd in, but are unavailable to any cron jobs. I've even tried running it as the user the cron job runs as and it works fine from my console.

                  当我在上述设置中运行 php artisan 时,我的自定义命令会列出并可用.但是,当我将 php artisan 作为 cron 作业运行时,它们没有列出.

                  When I run php artisan in the above settings, my custom commands are listed and available. However, they are not listed when I run php artisan as a cron job.

                  此外,尝试将自定义命令 php artisan subject:calculate 作为 cron 作业运行会导致以下错误:

                  Furthermore, trying to run the custom command php artisan subjects:calculate as a cron job results in the following error:

                  <代码>[无效参数异常]
                  主题"命名空间中没有定义命令.

                  推荐答案

                  我遇到了同样的错误,我找到了解决方案.第一次失败的尝试

                  I was fighting with the same error and I found the solution. First failed attempts

                  */5 * * * * /usr/bin/php /home/mysite/public_html/artisan my:command
                  
                  */5 * * * * php /home/mysite/public_html/artisan my:command
                  

                  解决方案

                  */5 * * * * /usr/local/bin/php /home/mysite/public_html/artisan my:command
                  

                  这篇关于无法通过 cron 作业使用自定义 Laravel Artisan 命令的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                  相关文档推荐

                  DeepL的翻译效果还是很强大的,如果我们要用php实现DeepL翻译调用,该怎么办呢?以下是代码示例,希望能够帮到需要的朋友。 在这里需要注意,这个DeepL的账户和api申请比较难,不支持中国大陆申请,需要拥有香港或者海外信用卡才行,没账号的话,目前某宝可以
                  PHP通过phpspreadsheet导入Excel日期,导入系统后,全部变为了4开头的几位数字,这是为什么呢?原因很简单,将Excel的时间设置问文本,我们就能看到该日期本来的数值,上图对应的数值为: 要怎么解决呢?进行数据转换就行,这里可以封装方法,或者用第三方的
                  mediatemple - can#39;t send email using codeigniter(mediatemple - 无法使用 codeigniter 发送电子邮件)
                  Laravel Gmail Configuration Error(Laravel Gmail 配置错误)
                  Problem with using PHPMailer for SMTP(将 PHPMailer 用于 SMTP 的问题)
                  Issue on how to setup SMTP using PHPMailer in GoDaddy server(关于如何在 GoDaddy 服务器中使用 PHPMailer 设置 SMTP 的问题)

                1. <legend id='1BVKu'><style id='1BVKu'><dir id='1BVKu'><q id='1BVKu'></q></dir></style></legend>
                        <i id='1BVKu'><tr id='1BVKu'><dt id='1BVKu'><q id='1BVKu'><span id='1BVKu'><b id='1BVKu'><form id='1BVKu'><ins id='1BVKu'></ins><ul id='1BVKu'></ul><sub id='1BVKu'></sub></form><legend id='1BVKu'></legend><bdo id='1BVKu'><pre id='1BVKu'><center id='1BVKu'></center></pre></bdo></b><th id='1BVKu'></th></span></q></dt></tr></i><div id='1BVKu'><tfoot id='1BVKu'></tfoot><dl id='1BVKu'><fieldset id='1BVKu'></fieldset></dl></div>
                        • <bdo id='1BVKu'></bdo><ul id='1BVKu'></ul>

                          <small id='1BVKu'></small><noframes id='1BVKu'>

                              <tbody id='1BVKu'></tbody>
                            <tfoot id='1BVKu'></tfoot>