From 6acbbd61dbef8a5333d5dd5777119c85472de064 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=98=BF=E5=BA=B7?= Date: Wed, 26 Dec 2018 13:19:36 +0800 Subject: [PATCH 1/4] config-repo init.. --- tamguo/pom.xml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tamguo/pom.xml b/tamguo/pom.xml index ad27545..2c1cf08 100644 --- a/tamguo/pom.xml +++ b/tamguo/pom.xml @@ -25,6 +25,10 @@ org.springframework.boot spring-boot-starter-web + + org.springframework.cloud + spring-cloud-starter-config + org.springframework.boot spring-boot-starter-thymeleaf From 9983280c8d0196ec56ab1c0b4b54047a6333e13e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=98=BF=E5=BA=B7?= Date: Sat, 29 Dec 2018 16:12:46 +0800 Subject: [PATCH 2/4] config server init ... --- ....properties => application-dev.properties} | 2 +- tanmguo-config-server/pom.xml | 67 ++++++++++++++ .../ConfigServerApplication.java | 22 +++++ .../src/main/resources/bootstrap.yml | 24 +++++ .../tanmguo-config-server.iml | 91 +++++++++++++++++++ .../target/classes/bootstrap.yml | 24 +++++ 6 files changed, 229 insertions(+), 1 deletion(-) rename tamguo/src/main/resources/{application.properties => application-dev.properties} (97%) create mode 100644 tanmguo-config-server/pom.xml create mode 100644 tanmguo-config-server/src/main/java/com.tamguo.config/ConfigServerApplication.java create mode 100644 tanmguo-config-server/src/main/resources/bootstrap.yml create mode 100644 tanmguo-config-server/tanmguo-config-server.iml create mode 100644 tanmguo-config-server/target/classes/bootstrap.yml diff --git a/tamguo/src/main/resources/application.properties b/tamguo/src/main/resources/application-dev.properties similarity index 97% rename from tamguo/src/main/resources/application.properties rename to tamguo/src/main/resources/application-dev.properties index 28c8229..ab00b4f 100644 --- a/tamguo/src/main/resources/application.properties +++ b/tamguo/src/main/resources/application-dev.properties @@ -13,7 +13,7 @@ spring.datasource.maxPoolPreparedStatementPerConnectionSize=20 spring.datasource.maxWait=60000 spring.datasource.minEvictableIdleTimeMillis=300000 spring.datasource.minIdle=5 -spring.datasource.password=Tanguo +spring.datasource.password=admin spring.datasource.poolPreparedStatements=true spring.datasource.testOnBorrow=false spring.datasource.testOnReturn=false diff --git a/tanmguo-config-server/pom.xml b/tanmguo-config-server/pom.xml new file mode 100644 index 0000000..ba334e7 --- /dev/null +++ b/tanmguo-config-server/pom.xml @@ -0,0 +1,67 @@ + + + 4.0.0 + com.tamguo + tanmguo-config-server + 1.0.0 + + + org.springframework.boot + spring-boot-starter-parent + 2.0.1.RELEASE + + + + + + org.springframework.cloud + spring-cloud-dependencies + Finchley.RELEASE + pom + import + + + + + + + org.springframework.cloud + spring-cloud-starter-config + + + + org.springframework.cloud + spring-cloud-config-server + + + + org.springframework.boot + spring-boot-starter-actuator + + + + org.springframework.cloud + spring-cloud-starter-eureka + + + + org.projectlombok + lombok + + + + + + tamguo-config-server + + + org.springframework.boot + spring-boot-maven-plugin + + + + + + \ No newline at end of file diff --git a/tanmguo-config-server/src/main/java/com.tamguo.config/ConfigServerApplication.java b/tanmguo-config-server/src/main/java/com.tamguo.config/ConfigServerApplication.java new file mode 100644 index 0000000..6536875 --- /dev/null +++ b/tanmguo-config-server/src/main/java/com.tamguo.config/ConfigServerApplication.java @@ -0,0 +1,22 @@ +package com.tamguo.config; + +import lombok.extern.slf4j.Slf4j; +import org.springframework.boot.CommandLineRunner; +import org.springframework.boot.SpringApplication; +import org.springframework.boot.autoconfigure.SpringBootApplication; +import org.springframework.cloud.config.server.EnableConfigServer; + +@SpringBootApplication +@EnableConfigServer +@Slf4j +public class ConfigServerApplication implements CommandLineRunner{ + + public static void main(String[] args) { + SpringApplication.run(ConfigServerApplication.class, args); + } + + @Override + public void run(String... args) throws Exception { + log.info(">>>>>>>>>>>>>>> tamguo-config-server 启动完成<<<<<<<<<<<<<"); + } +} diff --git a/tanmguo-config-server/src/main/resources/bootstrap.yml b/tanmguo-config-server/src/main/resources/bootstrap.yml new file mode 100644 index 0000000..86b8e02 --- /dev/null +++ b/tanmguo-config-server/src/main/resources/bootstrap.yml @@ -0,0 +1,24 @@ +server: + port: 9999 +spring: + application: + name: tamguo-config-server + cloud: + config: + allowOverride: true + server: + git: + uri: https://gitee.com/zhangshukang/tamguo-config-server-repo.git + username: 434329122@qq.com + password: + search-paths: tamguo + fail-fast: true + override-none: true #覆盖非系统属性 true不覆盖 + override-system-properties: true #覆盖系统属性 false不覆盖 + + + +logging: + level: + root: info + diff --git a/tanmguo-config-server/tanmguo-config-server.iml b/tanmguo-config-server/tanmguo-config-server.iml new file mode 100644 index 0000000..90d3fc7 --- /dev/null +++ b/tanmguo-config-server/tanmguo-config-server.iml @@ -0,0 +1,91 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/tanmguo-config-server/target/classes/bootstrap.yml b/tanmguo-config-server/target/classes/bootstrap.yml new file mode 100644 index 0000000..25bfd63 --- /dev/null +++ b/tanmguo-config-server/target/classes/bootstrap.yml @@ -0,0 +1,24 @@ +server: + port: 9999 +spring: + application: + name: tamguo-config-server + cloud: + config: + allowOverride: true + server: + git: + uri: https://gitee.com/zhangshukang/tamguo-config-server-repo.git + username: 434329122@qq.com + password: zklovecjj801122 + search-paths: tamguo + fail-fast: true + override-none: true #覆盖非系统属性 true不覆盖 + override-system-properties: true #覆盖系统属性 false不覆盖 + + + +logging: + level: + root: info + From c71a2e7be0e70d2e0113746875ed262b3c9712c0 Mon Sep 17 00:00:00 2001 From: SmileToCandy Date: Thu, 10 Jan 2019 16:46:49 +0800 Subject: [PATCH 3/4] =?UTF-8?q?=E6=9B=B4=E6=96=B0=20README.md?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 32 +++++++++++++++++++++++++++++--- 1 file changed, 29 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 940797f..8b1a1f8 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # tamguo 題庫 -![logo](https://www.tamguo.com/files/book/201812/1065126653186768898/logo_731bc32.png "logo") +![logo](https://images.gitee.com/uploads/images/2019/0110/164645_73f76413_93398.png "logo") # 简介 @@ -34,11 +34,11 @@ QQ群:937899574 # 项目结构 -![探果网项目结构](https://www.tamguo.com/files/book/201812/1077070399566454786/20181225135556.png "探果网项目结构") +![探果网项目结构](https://images.gitee.com/uploads/images/2019/0110/164645_39231d0a_93398.png "探果网项目结构") 1. `tamguo-common` 一些基础的工具类包 2. `tamguo-modules-core` 依赖`tamguo-common`,主要是核心业务包,包括数据处理,文件处理,邮件处理,短信处理等等。 -3. `tamguo-bms` 书籍系统[https://books.tamguo.com](https://books.tamguo.com "https://books.tamguo.com"),书籍系统展现层 +3. `tamguo-bms` 书籍系统[https://book.tamguo.com](https://books.tamguo.com "https://books.tamguo.com"),书籍系统展现层 4. `tamguo-mms`会员中心[https://member.tamguo.com](https://member.tamguo.com "https://member.tamguo.com") 5. `tamguo-oms`后台管理系统[https://admin.tamguo.com](https://member.tamguo.com "https://admin.tamguo.com") 6. `tamguo-crawler`爬虫程序,单独项目运行 @@ -48,6 +48,32 @@ QQ群:937899574 在`tamguo db`目录下 +### 开始 + + +> 安装 `redis` + +因为官网没有`windows redis`的版本,我们去github上下载windows版本的redis + +[redis windows 下载](https://github.com/MicrosoftArchive/redis/releases "redis window") + +下载`Redis-x64-3.2.100.zip`这个包,解压,执行`redis-server.exe`。 + +![redis 启动](https://images.gitee.com/uploads/images/2019/0110/164646_11648db7_93398.png "redis 启动") + +看到这个界面Redis就算启动成功。 + + +> 安装 `MYSQL` + +不做描述 + +> 安装 `jdk1.8` + +不做描述 + +至此`tamguo`的环境基本基本上已经安装好。 + > ### 捐赠 > 感谢你们的支持! From 4bcd82d02d34dc904b0a06f28193834f8a0989c0 Mon Sep 17 00:00:00 2001 From: SmileToCandy Date: Thu, 10 Jan 2019 17:01:01 +0800 Subject: [PATCH 4/4] =?UTF-8?q?=E6=9B=B4=E6=96=B0=20README.md?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 25 ++++++++++++++++++++++--- 1 file changed, 22 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 8b1a1f8..7578689 100644 --- a/README.md +++ b/README.md @@ -59,7 +59,7 @@ QQ群:937899574 下载`Redis-x64-3.2.100.zip`这个包,解压,执行`redis-server.exe`。 -![redis 启动](https://images.gitee.com/uploads/images/2019/0110/164646_11648db7_93398.png "redis 启动") +![redis 启动](https://www.tamguo.com/files/book/201901/1077070399566454786/redis.png "redis 启动") 看到这个界面Redis就算启动成功。 @@ -74,8 +74,27 @@ QQ群:937899574 至此`tamguo`的环境基本基本上已经安装好。 -> ### 捐赠 -> 感谢你们的支持! +### 启动 tms + +找到`tamguo-tms`下面的`application.propertys`。 + +- domain.name // 页面引用静态资源的前缀 +- member.domain.name // 会员系统跳转域名 +- cookie.domian.name // 关系到session,本地配置成local +- server.port // 服务端口 +- spring.datasource.url // 数据库连接地址 +- spring.datasource.username // 数据库连接用户名 +- redis.hostname // redis 服务地址 +- redis.port // redis 端口 +- file.storage.path // 上传文件存放路径 +确定`propertys`正确后,用springboot 方式启动应用。 +![启动成功](https://images.gitee.com/uploads/images/2019/0110/170054_8f975a9c_93398.png "启动成功") +到这里就启动成功了,访问 `http://localhost:8081/` + +到现在tms已经启动成功, tms 针对的用户(包括老师,学生等等)。 + +> ### 捐赠 +> 感谢你们的支持!