使用宝塔 部署 执行出现以下问题

Migration table created successfully.
Migrating: 2014_10_12_000000_create_users_table
Migrated:  2014_10_12_000000_create_users_table (0.02 seconds)
Migrating: 2014_10_12_100000_create_password_resets_table
Migrated:  2014_10_12_100000_create_password_resets_table (0.02 seconds)
Migrating: 2019_08_19_000000_create_failed_jobs_table
Migrated:  2019_08_19_000000_create_failed_jobs_table (0.08 seconds)
Migrating: 2019_09_26_143444_add_avatar_and_introduction_to_users_table
Migrated:  2019_09_26_143444_add_avatar_and_introduction_to_users_table (0.09 seconds)
Migrating: 2019_09_26_154619_create_categories_table
Migrated:  2019_09_26_154619_create_categories_table (0.02 seconds)
Migrating: 2019_09_26_155051_seed_categories_data
Migrated:  2019_09_26_155051_seed_categories_data (0 seconds)
Migrating: 2019_09_26_155555_create_topics_table
Migrated:  2019_09_26_155555_create_topics_table (0.18 seconds)
Migrating: 2019_09_27_114516_create_replies_table
Migrated:  2019_09_27_114516_create_replies_table (0.1 seconds)
Migrating: 2019_09_27_140305_create_notifications_table
Migrated:  2019_09_27_140305_create_notifications_table (0.11 seconds)
Migrating: 2019_09_27_140501_add_notification_count_to_users_table
Migrated:  2019_09_27_140501_add_notification_count_to_users_table (0.39 seconds)
Migrating: 2019_09_27_144124_create_permission_tables

   Symfony\Component\Debug\Exception\FatalThrowableError  : Call to a member function connect() on null

  at /www/wwwroot/cocky.fun/vendor/laravel/framework/src/Illuminate/Redis/RedisManager.php:107
    103| 
    104|         $options = $this->config['options'] ?? [];
    105| 
    106|         if (isset($this->config[$name])) {
  > 107|             return $this->connector()->connect(
    108|                 $this->parseConnectionConfiguration($this->config[$name]),
    109|                 $options
    110|             );
    111|         }

  Exception trace:

  1   Illuminate\Redis\RedisManager::resolve("cache")
      /www/wwwroot/cocky.fun/vendor/laravel/framework/src/Illuminate/Redis/RedisManager.php:88

  2   Illuminate\Redis\RedisManager::connection("cache")
      /www/wwwroot/cocky.fun/vendor/laravel/framework/src/Illuminate/Cache/RedisStore.php:242
《L05 电商实战》
从零开发一个电商项目,功能包括电商后台、商品 & SKU 管理、购物车、订单管理、支付宝支付、微信支付、订单退款流程、优惠券等
《L03 构架 API 服务器》
你将学到如 RESTFul 设计风格、PostMan 的使用、OAuth 流程,JWT 概念及使用 和 API 开发相关的进阶知识。
讨论数量: 3

看样子好像是php的Redis扩展没有安装吧

5年前 评论
lochpure

.env里面的redis配置没有生效,请检查你的配置信息。

5年前 评论

php artisan cache:clear php artisan config:clear 我也遇到这个问题了,尝试执行了清除缓存解决了问题。

4年前 评论

讨论应以学习和精进为目的。请勿发布不友善或者负能量的内容,与人为善,比聪明更重要!