|
@@ -3,7 +3,7 @@
|
|
|
## 开发环境
|
|
## 开发环境
|
|
|
Git克隆源代码到本地
|
|
Git克隆源代码到本地
|
|
|
```
|
|
```
|
|
|
-git clone http://www.leanwo.com:3000/ShangHaiLeanwo/FileServer.git
|
|
|
|
|
|
|
+git clone http://www.leanwo.com:3000/ShangHaiLeanwo/GatewayServer.git
|
|
|
```
|
|
```
|
|
|
源代码导入到eclipse中。注意事项如下:
|
|
源代码导入到eclipse中。注意事项如下:
|
|
|
1. 工作空间的编码格式设置成UTF-8。(Preferences-General-Workspace-Text file encoding-Other(UTF-8))
|
|
1. 工作空间的编码格式设置成UTF-8。(Preferences-General-Workspace-Text file encoding-Other(UTF-8))
|
|
@@ -15,7 +15,7 @@ git clone http://www.leanwo.com:3000/ShangHaiLeanwo/FileServer.git
|
|
|
* 修改端口号,打开resources/Application.yml,修改属性server.port可以修改启动的端口号。
|
|
* 修改端口号,打开resources/Application.yml,修改属性server.port可以修改启动的端口号。
|
|
|
```
|
|
```
|
|
|
server:
|
|
server:
|
|
|
- port: 85
|
|
|
|
|
|
|
+ port: 80
|
|
|
```
|
|
```
|
|
|
* 修改Eureka服务器的地址,尽量不要修改该属性,该属性来源于服务管理器(ServerManagement)中的eureka.serviceUrl.defaultZone属性
|
|
* 修改Eureka服务器的地址,尽量不要修改该属性,该属性来源于服务管理器(ServerManagement)中的eureka.serviceUrl.defaultZone属性
|
|
|
```
|
|
```
|
|
@@ -27,55 +27,16 @@ eureka:
|
|
|
serviceUrl:
|
|
serviceUrl:
|
|
|
defaultZone: http://localhost:88/eureka/
|
|
defaultZone: http://localhost:88/eureka/
|
|
|
```
|
|
```
|
|
|
-* 修改数据字典路径ProdogFileHome,修改resources/applicationContext.xml中的appConfig Bean的定义。
|
|
|
|
|
|
|
+* 修改zuul服务器的映射。
|
|
|
```
|
|
```
|
|
|
-<bean id="appConfig" class="com.leanwo.file.util.AppConfig">
|
|
|
|
|
- <!-- token -->
|
|
|
|
|
- <property name="token" value="123456"></property>
|
|
|
|
|
- <!-- Prodog File 文件夹的路径 -->
|
|
|
|
|
- <property name="prodogFileHome" value="D:\LeanwoProgram_2019\OtherServer\FileServer\content"></property>
|
|
|
|
|
-</bean>
|
|
|
|
|
|
|
+zuul:
|
|
|
|
|
+ # 隐藏所有微服务名称(即使用微服务名称无法访问到服务)
|
|
|
|
|
+ ignored-services: "*"
|
|
|
|
|
+ # 服务前缀名,想要访问项目之前要加上此路径
|
|
|
|
|
+ # prefix: /file-server
|
|
|
|
|
+ routes:
|
|
|
|
|
+ #只要访问以/editor/开头的多层目录都可以路由到服务名为file-server的服务上.
|
|
|
|
|
+ file-server:
|
|
|
|
|
+ serviceId: file-server
|
|
|
|
|
+ path: /**
|
|
|
```
|
|
```
|
|
|
-
|
|
|
|
|
-* 修改数据字典路径,修改resources/applicationContext-elfinder.xml中的fsServiceFactory Bean的定义,修改rootDir属性的定义。
|
|
|
|
|
-```
|
|
|
|
|
-<bean id="fsServiceFactory"
|
|
|
|
|
- ....
|
|
|
|
|
- <!-- two volumes are mounted here -->
|
|
|
|
|
- <map>
|
|
|
|
|
- <entry key="A">
|
|
|
|
|
- <bean class="cn.bluejoe.elfinder.localfs.LocalFsVolume">
|
|
|
|
|
- <property name="name" value="数据字典" />
|
|
|
|
|
- <property name="rootDir" value="D:\LeanwoProgram_2019\OtherServer\FileServer\content" />
|
|
|
|
|
- </bean>
|
|
|
|
|
- </entry>
|
|
|
|
|
- <entry key="B">
|
|
|
|
|
- <bean class="cn.bluejoe.elfinder.localfs.LocalFsVolume">
|
|
|
|
|
- <property name="name" value="客户数据" />
|
|
|
|
|
- <property name="rootDir" value="D:\LeanwoProgram_2019\OtherServer\FileServer\content\Files" />
|
|
|
|
|
- </bean>
|
|
|
|
|
- </entry>
|
|
|
|
|
- </map>
|
|
|
|
|
- ....
|
|
|
|
|
- </property>
|
|
|
|
|
- </bean>
|
|
|
|
|
-```
|
|
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
-* 修改FTP配置,修改resources/applicationContext.xml中的ftpServerConfig Bean的定义。
|
|
|
|
|
-```
|
|
|
|
|
-<bean id="ftpServerConfig" class="com.leanwo.file.server.FtpServerConfig">
|
|
|
|
|
- <!-- 是否启用FTP -->
|
|
|
|
|
- <property name="enable" value="false"></property>
|
|
|
|
|
- <!-- FTP通讯端口号 -->
|
|
|
|
|
- <property name="port" value="21"></property>
|
|
|
|
|
- <!-- 被动模式,FTP数据传输端口(必须大于1024) -->
|
|
|
|
|
- <property name="passivePorts" value="1034-1040"></property>
|
|
|
|
|
-</bean>
|
|
|
|
|
-```
|
|
|
|
|
-属性名称 | 属性定义 | 备注
|
|
|
|
|
--|-|-
|
|
|
|
|
-enable | 是否开启FTP服务 | true:开启FTP服务,false:不开启FTP服务 |
|
|
|
|
|
-port | FTP端口号 | 默认21 |
|
|
|
|
|
-passivePorts | FTP被动模式端口号 | 被动模式,FTP数据传输端口,默认值(必须大于1024)1034-1040 |
|
|
|
|
|
-
|
|
|