fix(config): Correct Redis high availability deployment
This commit is contained in:
@@ -0,0 +1,97 @@
|
||||
server:
|
||||
port: 9002
|
||||
|
||||
spring:
|
||||
application:
|
||||
name: video-user
|
||||
cloud:
|
||||
nacos:
|
||||
discovery:
|
||||
server-addr: ${NACOS_SERVERS:192.168.1.101:8848,192.168.1.102:8848,192.168.1.103:8848}
|
||||
namespace: ${NACOS_NAMESPACE:public}
|
||||
group: ${NACOS_GROUP:DEFAULT_GROUP}
|
||||
username: nacos
|
||||
password: nacos
|
||||
ip: ${USER_IP:}
|
||||
config:
|
||||
server-addr: ${spring.cloud.nacos.discovery.server-addr}
|
||||
namespace: ${spring.cloud.nacos.discovery.namespace}
|
||||
group: ${spring.cloud.nacos.discovery.group}
|
||||
file-extension: yaml
|
||||
username: nacos
|
||||
password: nacos
|
||||
sentinel:
|
||||
transport:
|
||||
dashboard: ${SENTINEL_HOST:sentinel}:${SENTINEL_PORT:8080}
|
||||
port: 8722
|
||||
client-ip: ${USER_IP:}
|
||||
eager: true
|
||||
datasource:
|
||||
url: jdbc:mysql://${MYSQL_HOST:mysql}:${MYSQL_PORT:3306}/video_user?useUnicode=true&characterEncoding=utf-8&useSSL=false&serverTimezone=Asia/Shanghai&allowPublicKeyRetrieval=true&allowMultiQueries=true
|
||||
username: root
|
||||
password: ${MYSQL_ROOT_PASSWORD:root123456}
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
hikari:
|
||||
max-lifetime: 58000
|
||||
idle-timeout: 300000
|
||||
connection-timeout: 20000
|
||||
connection-test-query: SELECT 1
|
||||
keepalive-time: 60000
|
||||
validation-timeout: 3000
|
||||
minimum-idle: 5
|
||||
maximum-pool-size: 20
|
||||
data:
|
||||
redis:
|
||||
password: ${REDIS_PASSWORD:redis_HA_Cluster_2024}
|
||||
database: 1
|
||||
timeout: 10000
|
||||
sentinel:
|
||||
master: mymaster
|
||||
nodes: ${REDIS_SENTINEL_NODES:192.168.1.101:26379,192.168.1.102:26379,192.168.1.103:26379}
|
||||
password: ${REDIS_PASSWORD:redis_HA_Cluster_2024}
|
||||
lettuce:
|
||||
pool:
|
||||
max-active: 200
|
||||
max-wait: -1
|
||||
max-idle: 10
|
||||
min-idle: 0
|
||||
|
||||
mybatis-plus:
|
||||
mapper-locations: classpath:mapper/*.xml
|
||||
type-aliases-package: com.nuaa.video.user.entity
|
||||
configuration:
|
||||
map-underscore-to-camel-case: true
|
||||
cache-enabled: false
|
||||
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
|
||||
global-config:
|
||||
db-config:
|
||||
id-type: auto
|
||||
logic-delete-field: is_deleted
|
||||
logic-delete-value: 1
|
||||
logic-not-delete-value: 0
|
||||
|
||||
auth:
|
||||
ignore-urls:
|
||||
- /user/profile/public/**
|
||||
- /user/profile/init
|
||||
- /actuator/**
|
||||
|
||||
management:
|
||||
endpoints:
|
||||
web:
|
||||
exposure:
|
||||
include: '*'
|
||||
endpoint:
|
||||
health:
|
||||
show-details: always
|
||||
|
||||
logging:
|
||||
level:
|
||||
com.nuaa.video: info
|
||||
org.springframework.security: info
|
||||
|
||||
minio:
|
||||
endpoint: http://${MINIO_HOST:minio}:${MINIO_PORT:9000}
|
||||
accessKey: minioadmin
|
||||
secretKey: minioadmin123
|
||||
bucketName: video-platform
|
||||
Reference in New Issue
Block a user