From a1393973c613ed60608b44086aba92066cd51738 Mon Sep 17 00:00:00 2001
From: PoffyZhang <99775271@qq.com>
Date: Tue, 3 Jan 2023 16:52:08 +0800
Subject: [PATCH] =?UTF-8?q?pom=20=E5=BC=95=E5=85=A5swagger=E5=92=8Cflowabl?=
=?UTF-8?q?e?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
pmapi/pom.xml | 35 +++++++-----
pmapi/src/main/resources/application-dev.yml | 79 +++++++++++++++++++++++++-
pmapi/src/main/resources/logback-spring.xml | 68 ++++++++++++++++++++++
pmapi/src/main/resources/security/auth-dev.yml | 2 +
pom.xml | 5 ++
5 files changed, 173 insertions(+), 16 deletions(-)
create mode 100644 pmapi/src/main/resources/logback-spring.xml
diff --git a/pmapi/pom.xml b/pmapi/pom.xml
index be79e65..18759df 100644
--- a/pmapi/pom.xml
+++ b/pmapi/pom.xml
@@ -63,20 +63,6 @@
tomcat-embed-core
- com.ningdatech
- nd-swagger2-starter
-
-
- org.slf4j
- slf4j-log4j12
-
-
-
-
- com.ningdatech
- nd-flowable-starter
-
-
org.springframework.boot
spring-boot-starter-validation
@@ -241,7 +227,26 @@
com.ningdatech
nd-basic
- 1.0.0
+
+
+ org.slf4j
+ slf4j-log4j12
+
+
+
+
+ com.ningdatech
+ nd-swagger2-starter
+
+
+ org.slf4j
+ slf4j-log4j12
+
+
+
+
+ com.ningdatech
+ nd-flowable-starter
diff --git a/pmapi/src/main/resources/application-dev.yml b/pmapi/src/main/resources/application-dev.yml
index 23541d7..44509ba 100644
--- a/pmapi/src/main/resources/application-dev.yml
+++ b/pmapi/src/main/resources/application-dev.yml
@@ -2,5 +2,82 @@ server:
port: 28888
servlet:
context-path: /pm
+
+spring:
+ mvc:
+ pathmatch:
+ matching-strategy: ant_path_matcher
+ session:
+ store-type: redis
+ redis:
+ namespace: "spring:session"
+ redis:
+ timeout: 5000
+ host: 47.98.125.47
+ port: 26379
+ database: 0
+ password: Ndkj1234
+ jedis:
+ pool:
+ max-active: 200
+ max-idle: 500
+ min-idle: 8
+ max-wait: 10000
+ application:
+ name: cm
+ jackson:
+ default-property-inclusion: non_null
+ time-zone: GMT+8
+ date-format: yyyy-MM-dd HH:mm:ss
+ datasource:
+ url: jdbc:mysql://localhost:3306/wflow?useSSL=false&useUnicode=true&characterEncoding=utf8
+ driverClassName: com.mysql.jdbc.Driver
+ username: root
+ password: 123456
+ druid:
+ max-wait: 10000
+ min-idle: 5
+ max-active: 100
+
+ #邮件发送配置
+ mail:
+ host:
+ username:
+ password:
+ protocol: smtps
+ default-encoding: UTF-8
+ properties:
+ default-encoding: utf-8
+ mail:
+ smtp:
+ port: 465
+ auth: true
+ starttls:
+ enable: true
+ required: true
+
logging:
- config: classpath:logback-spring.xml
\ No newline at end of file
+ config: classpath:logback-spring.xml
+#日志配置
+ level:
+ root: info
+ file:
+ path: logs
+nd:
+ log:
+ enabled: true
+ type: DB
+# 日志文件配置
+log:
+ path: ./logs
+ info:
+ file-size: 50MB
+ max-size: 5
+ total-size: 200MB
+ error:
+ file-size: 10MB
+ max-size: 5
+ total-size: 50MB
+
+swagger:
+ enabled: true
\ No newline at end of file
diff --git a/pmapi/src/main/resources/logback-spring.xml b/pmapi/src/main/resources/logback-spring.xml
new file mode 100644
index 0000000..75f5472
--- /dev/null
+++ b/pmapi/src/main/resources/logback-spring.xml
@@ -0,0 +1,68 @@
+
+
+
+
+
+
+
+
+
+
+ ${logPath}/info.log
+
+ ${logPath}/info-%d{yyyyMMdd}-%i.log
+
+ ${infoFileSize}
+
+ ${infoMaxSize}
+ ${infoTotalSize}
+
+
+
+ %d{yyyy-MM-dd HH:mm:ss.SSS} [%thread] %-5level %logger{36} -%msg%n
+
+
+ UTF-8
+
+
+
+
+
+ ERROR
+
+ ${logPath}/error.log
+
+ ${logPath}/error-%d{yyyyMMdd}-%i.log
+
+ ${errorFileSize}
+
+ ${errorMaxSize}
+ ${errorTotalSize}
+
+
+
+ %d{yyyy-MM-dd HH:mm:ss.SSS} [%thread] %-5level %logger{36} -%msg%n
+
+
+ UTF-8
+
+
+
+
+
+
+ %d{yyyy-MM-dd HH:mm:ss.SSS} [%thread] %-5level %logger{36} -%msg%n
+
+ UTF-8
+
+
+ DEBUG
+
+
+
+
+
+
+
+
+
diff --git a/pmapi/src/main/resources/security/auth-dev.yml b/pmapi/src/main/resources/security/auth-dev.yml
index 1341250..887aed5 100644
--- a/pmapi/src/main/resources/security/auth-dev.yml
+++ b/pmapi/src/main/resources/security/auth-dev.yml
@@ -18,6 +18,7 @@ security:
- /doc.html
- /ok.html
- /open/api/**
+ - /oa/**
ignore-csrf-urls:
- /api/v1/user/auth/**
- /v2/api-docs
@@ -31,6 +32,7 @@ security:
- /file/**
- /optLog/**
- /dict/**
+ - /oa/**
role-map:
"engineer":
"project_manager":
diff --git a/pom.xml b/pom.xml
index 6657691..ba0603e 100644
--- a/pom.xml
+++ b/pom.xml
@@ -88,6 +88,11 @@
com.ningdatech
+ nd-basic
+ 1.0.0
+
+
+ com.ningdatech
nd-swagger2-starter
1.0.0