Skip to content

erruicoders/community

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 

Repository files navigation

码问

功能列表

开源论坛、问答系统,现有功能多社交平台登录(Github,Gitee)提问、回复、通知、最新问答、最热热大、消除零回复等功能。

本地运行手册

  1. 安装必备工具
    JDK,Maven
  2. 克隆代码到本地
git clone https://github.com/codedrinker/community.git
  1. 运行数据库脚本,创建本地数据库
mvn flyway:migrate

如果需要使用 MySQL 数据库,运行脚本前修改两处配置

# src/main/resources/application.properties 
spring.datasource.url=jdbc:h2:~/community
spring.datasource.username=sa
spring.datasource.password=123
# pom.xml
<properties>
    <db.url>jdbc:h2:~/community</db.url>
    <db.user>sa</db.user>
    <db.password>123</db.password>
</properties>
  1. 运行打包命令,生成可执行 jar 文件
mvn package -DskipTests
  1. 运行项目
java -jar target/community-0.0.1-SNAPSHOT.jar

如果是线上部署,可以增加配置文件(production.properties),同时运行命令修改如下

java -jar -Dspring.profiles.active=production target/community-0.0.1-SNAPSHOT.jar
  1. 访问项目
http://localhost:8887

技术栈

技术 链接
Spring Boot http://projects.spring.io/spring-boot/#quick-start
MyBatis https://mybatis.org/mybatis-3/zh/index.html
MyBatis Generator http://mybatis.org/generator/
H2 http://www.h2database.com/html/main.html
Flyway https://flywaydb.org/getstarted/firststeps/maven
Lombok https://www.projectlombok.org
Bootstrap https://v3.bootcss.com/getting-started/
Github OAuth https://developer.github.com/apps/building-oauth-apps/creating-an-oauth-app/
UFile https://github.com/ucloud/ufile-sdk-java
Bootstrap https://v3.bootcss.com/getting-started/

脚本

create table USER
(
ID           INT auto_increment,
ACCOUNT_ID   VARCHAR(100),
NAME         VARCHAR(50),
TOKEN        CHAR(36),
GMT_CREATE   BIGINT,
GMT_MODIFIED BIGINT,
constraint USER_PK
primary key (ID)
);

comment on table USER is '用户表';

扩展资料

Spring 文档
Spring Web
es
Github deploy key
Bootstrap
Github OAuth
Spring
菜鸟教程
Thymeleaf
Spring Dev Tool
Spring MVC
Markdown 插件
UFfile SDK
Count(*) VS Count(1)
Git
Visual Paradigm
Flyway
Lombok
ctotree
Table of content sidebar
One Tab
Live Reload
Postman

About

community

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published