From 119c25060a3b5558553c148fd654893cad1a2bb1 Mon Sep 17 00:00:00 2001 From: luke Date: Sat, 7 Jun 2025 02:11:18 +0800 Subject: [PATCH] fix redis bug --- src/main/resources/application-docker.properties | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/main/resources/application-docker.properties b/src/main/resources/application-docker.properties index 8752f6f..d947c49 100644 --- a/src/main/resources/application-docker.properties +++ b/src/main/resources/application-docker.properties @@ -40,11 +40,12 @@ mybatis-plus.configuration.log-impl=org.apache.ibatis.logging.stdout.StdOutImpl mybatis-plus.global-config.db-config.logic-delete-field=deleted mybatis-plus.global-config.db-config.id-type=auto -# Redis 开关控制 +# 自定义 Redis 配置(用于 RedisConfig 类) knowledge.base.redis.enable=true -# Redis 服务配置 knowledge.base.redis.host=host.docker.internal knowledge.base.redis.port=6379 -knowledge.base.redis.password= # 可留空 -# Redis 默认缓存时间(分钟) -knowledge.base.redis.default-expire-minutes=1440 \ No newline at end of file +knowledge.base.redis.default-expire-minutes=1440 + +# Spring Boot Redis 自动配置(用于 RedisTemplate 和 Lettuce) +spring.redis.host=host.docker.internal +spring.redis.port=6379