Browse Source

1.增加配送模块的Dockerfile

dev-warehouse
pref_mail@163.com 2 years ago
parent
commit
cb25719263
  1. 14
      blade-service/logpm-distribution/Dockerfile
  2. 21
      blade-service/logpm-distribution/src/main/resources/application-test.yml

14
blade-service/logpm-distribution/Dockerfile

@ -0,0 +1,14 @@
FROM bladex/alpine-java:openjdk8-openj9_cn_slim
MAINTAINER h5u@163.com
RUN mkdir -p /logpm/distribution
WORKDIR /logpm/distribution
EXPOSE 8500
ADD ./target/logpm-distribution.jar ./app.jar
ENTRYPOINT ["java", "-Djava.security.egd=file:/dev/./urandom", "-jar", "app.jar"]
CMD ["--spring.profiles.active=test"]

21
blade-service/logpm-distribution/src/main/resources/application-test.yml

@ -1,13 +1,13 @@
#服务器端口
server:
port: 8200
port: 8500
#数据源配置
#spring:
# datasource:
# url: ${blade.datasource.test.url}
# username: ${blade.datasource.test.username}
# password: ${blade.datasource.test.password}
# url: ${blade.datasource.dev.url}
# username: ${blade.datasource.dev.username}
# password: ${blade.datasource.dev.password}
spring:
#排除DruidDataSourceAutoConfigure
@ -16,16 +16,29 @@ spring:
datasource:
dynamic:
druid:
#通用校验配置
validation-query: select 1
#启用sql日志拦截器
proxy-filters:
- sqlLogInterceptor
#设置默认的数据源或者数据源组,默认值即为master
primary: master
datasource:
master:
druid:
#独立校验配置
validation-query: select 1
#oracle校验
#validation-query: select 1 from dual
url: ${blade.datasource.distribution.master.url}
username: ${blade.datasource.distribution.master.username}
password: ${blade.datasource.distribution.master.password}
slave:
druid:
#独立校验配置
validation-query: select 1
#oracle校验
#validation-query: select 1 from dual
url: ${blade.datasource.distribution.slave.url}
username: ${blade.datasource.distribution.slave.username}
password: ${blade.datasource.distribution.slave.password}

Loading…
Cancel
Save