Browse Source

[修改]配置文件调整

13660505945 1 week ago
parent
commit
9c30492c14

+ 23 - 0
src/main/resources/application-dev.yml

@@ -0,0 +1,23 @@
+server:
+  #端口号
+  port: 8080
+  tomcat:
+    basedir: F:/kaifa/temp #文件上传临时路径
+
+#文件上传方式 1-本机 2-oss
+file:
+  uploadType: 1
+  path: F:/kaifa/file #文件上传根目录
+
+spring:
+  #数据库连接
+  datasource:
+    url: jdbc:mysql://localhost:3306/jsh_erp?useUnicode=true&characterEncoding=utf8&useCursorFetch=true&defaultFetchSize=500&allowMultiQueries=true&rewriteBatchedStatements=true&useSSL=false
+    driverClassName: com.mysql.cj.jdbc.Driver
+    username: root
+    password: 123456
+  # Redis
+  redis:
+    host: 127.0.0.1
+    port: 6379
+    password:

+ 23 - 0
src/main/resources/application-pro.yml

@@ -0,0 +1,23 @@
+server:
+  #端口号
+  port: 8080
+  tomcat:
+    basedir: /opt/tmp/tomcat #文件上传临时路径
+
+#文件上传方式 1-本机 2-oss
+file:
+  uploadType: 1
+  path: /opt/jshERP/upload #文件上传根目录
+
+spring:
+  #数据库连接
+  datasource:
+    url: jdbc:mysql://localhost:3306/jsh_erp?useUnicode=true&characterEncoding=utf8&useCursorFetch=true&defaultFetchSize=500&allowMultiQueries=true&rewriteBatchedStatements=true&useSSL=false
+    driverClassName: com.mysql.cj.jdbc.Driver
+    username: root
+    password: jiesuimysql2022
+  # Redis
+  redis:
+    host: 127.0.0.1
+    port: 16379
+    password: jiesuiredis2022

+ 23 - 0
src/main/resources/application-test.yml

@@ -0,0 +1,23 @@
+server:
+  #端口号
+  port: 8082
+  tomcat:
+    basedir: /home/ruoyi/uploadTemp #文件上传临时路径
+
+#文件上传方式 1-本机 2-oss
+file:
+  uploadType: 1
+  path: /opt/jshERP/upload #文件上传根目录
+
+spring:
+  #数据库连接
+  datasource:
+    url: jdbc:mysql://localhost:3306/jsh_erp?useUnicode=true&characterEncoding=utf8&useCursorFetch=true&defaultFetchSize=500&allowMultiQueries=true&rewriteBatchedStatements=true&useSSL=false
+    driverClassName: com.mysql.cj.jdbc.Driver
+    username: root
+    password: Hro@2021Hro
+  # Redis
+  redis:
+    host: 127.0.0.1
+    port: 16379
+    password: jiesuiredis2022

+ 2 - 27
src/main/resources/application.yml

@@ -1,13 +1,3 @@
-server:
-  #端口号
-  port: 8080
-  servlet:
-    session:
-      timeout: 36000 #登录超时-秒
-    context-path: /jshERP-boot #服务路径
-  tomcat:
-    basedir: /opt/tmp/tomcat #文件上传临时路径
-
 #mybatis-plus配置
 mybatis-plus:
   # 对应的 XML 文件位置
@@ -27,24 +17,9 @@ plugin:
   pluginPath: plugins
   pluginConfigFilePath: pluginConfig
 
-#文件上传方式 1-本机 2-oss
-file:
-  uploadType: 1
-  path: /opt/jshERP/upload #文件上传根目录
-
 spring:
-  #数据库连接
-  datasource:
-    url: jdbc:mysql://localhost:3306/jsh_erp?useUnicode=true&characterEncoding=utf8&useCursorFetch=true&defaultFetchSize=500&allowMultiQueries=true&rewriteBatchedStatements=true&useSSL=false
-    driverClassName: com.mysql.cj.jdbc.Driver
-    username: root
-    password: 123456
-  # Redis
-  redis:
-    host: 127.0.0.1
-    port: 6379
-    password: foobared
-
+  profiles:
+    active: test
   servlet:
     #文件上传限制(byte)
     multipart: