项目修改
This commit is contained in:
parent
f3e5078c57
commit
0500ce708f
6 changed files with 37 additions and 11 deletions
25
Dockerfile
Normal file
25
Dockerfile
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
FROM java:8u111-jdk
|
||||
|
||||
#作者
|
||||
LABEL maintainer="peng"
|
||||
|
||||
# 设置工作目录
|
||||
WORKDIR /app
|
||||
|
||||
#容器数据卷,用于数据保存和持久化工作,可为 Spring Boot 临时文件提供持久化存储
|
||||
VOLUME /tmp
|
||||
|
||||
# 设置环境变量
|
||||
ENV LANG C.UTF-8
|
||||
|
||||
ENV TZ "Asia/Shanghai"
|
||||
|
||||
COPY target/songshui.jar /app/app.jar
|
||||
|
||||
# 暴露端口(与 Spring Boot 配置一致)
|
||||
EXPOSE 8964
|
||||
|
||||
# 在镜像运行为容器后执行的命令
|
||||
ENTRYPOINT ["sh","-c","java ${APP_OPTS} -jar /app/app.jar ${APP_PARMS}"]
|
||||
|
||||
|
||||
|
|
@ -9,8 +9,6 @@ import org.springframework.transaction.annotation.EnableTransactionManagement;
|
|||
|
||||
@Slf4j
|
||||
@EnableScheduling
|
||||
@EnableAsync
|
||||
@EnableTransactionManagement
|
||||
@SpringBootApplication
|
||||
public class SqxApplication {
|
||||
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@ public class ShiroConfig {
|
|||
filterMap.put("/swagger-ui.html", "anon");
|
||||
filterMap.put("/swagger-ui/*", "anon");
|
||||
filterMap.put("/swagger-resources/**", "anon");
|
||||
filterMap.put("/captcha.jpg", "anon");
|
||||
filterMap.put("/sys/captcha", "anon");
|
||||
filterMap.put("/chatSocket/**", "anon");
|
||||
filterMap.put("/websocket/**", "anon");
|
||||
filterMap.put("/search/**", "anon");
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ public class SysLoginController extends AbstractController {
|
|||
/**
|
||||
* 验证码
|
||||
*/
|
||||
@GetMapping("captcha.jpg")
|
||||
@GetMapping("/sys/captcha")
|
||||
public void captcha(HttpServletResponse response, String uuid)throws IOException {
|
||||
response.setHeader("Cache-Control", "no-store, no-cache");
|
||||
response.setContentType("image/jpeg");
|
||||
|
|
|
|||
|
|
@ -3,9 +3,9 @@ spring:
|
|||
type: com.alibaba.druid.pool.DruidDataSource
|
||||
druid:
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
url: jdbc:mysql://127.0.0.1:3306/songshui?useUnicode=true&characterEncoding=utf-8&useSSL=false&serverTimezone=CTT
|
||||
username: root
|
||||
password: 123456
|
||||
url: jdbc:mysql://${DB_URL:127.0.0.1}:3306/songshui?useUnicode=true&characterEncoding=utf-8&useSSL=false&serverTimezone=CTT
|
||||
username: ${DB_NAME}
|
||||
password: ${DB_PASSWORD}
|
||||
initial-size: 10
|
||||
max-active: 100
|
||||
min-idle: 10
|
||||
|
|
|
|||
|
|
@ -1,6 +1,3 @@
|
|||
logging:
|
||||
file:
|
||||
name: logs/songshui.log
|
||||
# Tomcat
|
||||
server:
|
||||
tomcat:
|
||||
|
|
@ -86,3 +83,9 @@ sqx:
|
|||
# token有效时长,7天,单位秒
|
||||
expire: 2592000
|
||||
header: token
|
||||
|
||||
logging:
|
||||
level:
|
||||
root: info
|
||||
file:
|
||||
name: songshui.log
|
||||
Loading…
Reference in a new issue