55 lines
1.5 KiB
YAML
55 lines
1.5 KiB
YAML
server:
|
||
port: 8100
|
||
servlet:
|
||
context-path: /api
|
||
|
||
spring:
|
||
profiles:
|
||
active: local
|
||
application:
|
||
name: smile-picture-backend
|
||
# 数据库配置
|
||
datasource:
|
||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||
url: jdbc:mysql://localhost:3306/smile-picture
|
||
username: root
|
||
password: 123456
|
||
servlet:
|
||
multipart:
|
||
max-file-size: 10MB
|
||
max-request-size: 10MB
|
||
|
||
mybatis-plus:
|
||
type-aliases-package: edu.whut.smilepicturebackend.model.entity
|
||
configuration:
|
||
# MyBatis 配置
|
||
map-underscore-to-camel-case: true #是否开启驼峰转换
|
||
# 仅在开发环境打印日志
|
||
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
|
||
global-config:
|
||
enable-sql-runner: true
|
||
db-config:
|
||
logic-delete-field: isDelete # 全局逻辑删除的实体字段名 删除操作时表中数据不会被物理删除,只会设置isDelete为1
|
||
logic-delete-value: 1 # 逻辑已删除值(默认为 1)
|
||
logic-not-delete-value: 0 # 逻辑未删除值(默认为 0)
|
||
|
||
# 接口文档配置
|
||
knife4j:
|
||
enable: true
|
||
openapi:
|
||
title: 接口文档
|
||
version: 1.0
|
||
group:
|
||
default:
|
||
api-rule: package
|
||
api-rule-resources:
|
||
- edu.whut.smilepicturebackend.controller #接口地址
|
||
|
||
# 对象存储配置(需要从腾讯云获取)
|
||
cos:
|
||
client:
|
||
host: ${smile-picture.cos.client.host}
|
||
secretId: ${smile-picture.cos.client.secretId}
|
||
secretKey: ${smile-picture.cos.client.secretKey}
|
||
region: ${smile-picture.cos.client.region}
|
||
bucket: ${smile-picture.cos.client.bucket} |