add: docker env contain payment module
This commit is contained in:
39
docker/copy.bat
Normal file
39
docker/copy.bat
Normal file
@@ -0,0 +1,39 @@
|
|||||||
|
@echo off
|
||||||
|
|
||||||
|
echo begin copy sql
|
||||||
|
copy ..\sql\wfc-cloud.sql .\mysql\db
|
||||||
|
copy ..\sql\wfc-config.sql .\mysql\db
|
||||||
|
|
||||||
|
REM 复制 HTML 文件
|
||||||
|
echo begin copy html
|
||||||
|
xcopy /E /I ..\..\fe.wfc\dist\* .\nginx\html\dist
|
||||||
|
|
||||||
|
REM 复制 JAR 文件
|
||||||
|
echo begin copy wfc-gateway
|
||||||
|
copy ..\wfc-gateway\target\wfc-gateway.jar .\wfc\gateway\jar
|
||||||
|
|
||||||
|
echo begin copy wfc-auth
|
||||||
|
copy ..\wfc-auth\target\wfc-auth.jar .\wfc\auth\jar
|
||||||
|
|
||||||
|
echo begin copy wfc-visual
|
||||||
|
copy ..\wfc-visual\wfc-monitor\target\wfc-visual-monitor.jar .\wfc\visual\monitor\jar
|
||||||
|
|
||||||
|
echo begin copy wfc-modules-system
|
||||||
|
copy ..\wfc-modules\wfc-system\target\wfc-modules-system.jar .\wfc\modules\system\jar
|
||||||
|
|
||||||
|
echo begin copy wfc-modules-user
|
||||||
|
copy ..\wfc-modules\wfc-modules-user\target\wfc-modules-user.jar .\wfc\modules\user\jar
|
||||||
|
|
||||||
|
echo begin copy wfc-modules-file
|
||||||
|
copy ..\wfc-modules\wfc-file\target\wfc-modules-file.jar .\wfc\modules\file\jar
|
||||||
|
|
||||||
|
echo begin copy wfc-modules-job
|
||||||
|
copy ..\wfc-modules\wfc-job\target\wfc-modules-job.jar .\wfc\modules\job\jar
|
||||||
|
|
||||||
|
echo begin copy wfc-modules-gen
|
||||||
|
copy ..\wfc-modules\wfc-gen\target\wfc-modules-gen.jar .\wfc\modules\gen\jar
|
||||||
|
|
||||||
|
echo begin copy wfc-modules-payment
|
||||||
|
copy ..\wfc-modules\wfc-payment\target\wfc-modules-payment.jar .\wfc\modules\payment\jar
|
||||||
|
|
||||||
|
exit /b 0
|
||||||
@@ -42,3 +42,5 @@ cp ../wfc-modules/wfc-job/target/wfc-modules-job.jar ./wfc/modules/job/jar
|
|||||||
echo "begin copy wfc-modules-gen "
|
echo "begin copy wfc-modules-gen "
|
||||||
cp ../wfc-modules/wfc-gen/target/wfc-modules-gen.jar ./wfc/modules/gen/jar
|
cp ../wfc-modules/wfc-gen/target/wfc-modules-gen.jar ./wfc/modules/gen/jar
|
||||||
|
|
||||||
|
echo "begin copy wfc-modules-payment "
|
||||||
|
cp -rf ../wfc-modules/wfc-payment/target/wfc-modules-payment.jar ./wfc/modules/payment/jar
|
||||||
|
|||||||
67
docker/deploy.bat
Normal file
67
docker/deploy.bat
Normal file
@@ -0,0 +1,67 @@
|
|||||||
|
@echo off
|
||||||
|
|
||||||
|
REM 根据输入参数,选择执行对应方法,不输入则执行使用说明
|
||||||
|
if "%1"=="port" goto port
|
||||||
|
if "%1"=="base" goto base
|
||||||
|
if "%1"=="modules" goto modules
|
||||||
|
if "%1"=="backend" goto backend
|
||||||
|
if "%1"=="frontend" goto frontend
|
||||||
|
if "%1"=="stop" goto stop
|
||||||
|
if "%1"=="rm" goto rm
|
||||||
|
goto usage
|
||||||
|
|
||||||
|
REM 使用说明,用来提示输入参数
|
||||||
|
:usage
|
||||||
|
echo Usage: deploy.bat [port^|base^|modules^|stop^|rm]
|
||||||
|
exit /b 1
|
||||||
|
|
||||||
|
REM 开启所需端口
|
||||||
|
:port
|
||||||
|
netsh advfirewall firewall add rule name="Open Port 80" dir=in action=allow protocol=TCP localport=80
|
||||||
|
netsh advfirewall firewall add rule name="Open Port 8080" dir=in action=allow protocol=TCP localport=8080
|
||||||
|
netsh advfirewall firewall add rule name="Open Port 8848" dir=in action=allow protocol=TCP localport=8848
|
||||||
|
netsh advfirewall firewall add rule name="Open Port 9848" dir=in action=allow protocol=TCP localport=9848
|
||||||
|
netsh advfirewall firewall add rule name="Open Port 9849" dir=in action=allow protocol=TCP localport=9849
|
||||||
|
netsh advfirewall firewall add rule name="Open Port 6379" dir=in action=allow protocol=TCP localport=6379
|
||||||
|
netsh advfirewall firewall add rule name="Open Port 3306" dir=in action=allow protocol=TCP localport=3306
|
||||||
|
netsh advfirewall firewall add rule name="Open Port 9100" dir=in action=allow protocol=TCP localport=9100
|
||||||
|
netsh advfirewall firewall add rule name="Open Port 9200" dir=in action=allow protocol=TCP localport=9200
|
||||||
|
netsh advfirewall firewall add rule name="Open Port 9201" dir=in action=allow protocol=TCP localport=9201
|
||||||
|
netsh advfirewall firewall add rule name="Open Port 9202" dir=in action=allow protocol=TCP localport=9202
|
||||||
|
netsh advfirewall firewall add rule name="Open Port 9203" dir=in action=allow protocol=TCP localport=9203
|
||||||
|
netsh advfirewall firewall add rule name="Open Port 9300-9399" dir=in action=allow protocol=TCP localport=9300-9399
|
||||||
|
net stop mpssvc
|
||||||
|
net start mpssvc
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
REM 启动基础环境(必须)
|
||||||
|
:base
|
||||||
|
docker-compose up -d wfc-mysql wfc-redis wfc-nacos
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
REM 启动程序模块(必须)
|
||||||
|
:modules
|
||||||
|
docker-compose up -d wfc-nginx wfc-gateway wfc-auth wfc-modules-system wfc-modules-user wfc-modules-payment
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
REM 启动程序模块(后端)
|
||||||
|
:backend
|
||||||
|
docker-compose up -d wfc-gateway wfc-auth wfc-modules-system wfc-modules-user wfc-modules-payment
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
REM 启动程序模块(前端)
|
||||||
|
:frontend
|
||||||
|
docker-compose up -d wfc-nginx
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
REM 关闭所有环境/模块
|
||||||
|
:stop
|
||||||
|
docker-compose stop
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
REM 删除所有环境/模块
|
||||||
|
:rm
|
||||||
|
docker-compose rm
|
||||||
|
exit /b 0
|
||||||
|
|
||||||
|
|
||||||
@@ -20,7 +20,7 @@ port(){
|
|||||||
firewall-cmd --add-port=9201/tcp --permanent
|
firewall-cmd --add-port=9201/tcp --permanent
|
||||||
firewall-cmd --add-port=9202/tcp --permanent
|
firewall-cmd --add-port=9202/tcp --permanent
|
||||||
firewall-cmd --add-port=9203/tcp --permanent
|
firewall-cmd --add-port=9203/tcp --permanent
|
||||||
firewall-cmd --add-port=9300/tcp --permanent
|
firewall-cmd --add-port=9300-9399/tcp --permanent
|
||||||
service firewalld restart
|
service firewalld restart
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -31,12 +31,12 @@ base(){
|
|||||||
|
|
||||||
# 启动程序模块(必须)
|
# 启动程序模块(必须)
|
||||||
modules(){
|
modules(){
|
||||||
docker-compose up -d wfc-nginx wfc-gateway wfc-auth wfc-modules-system wfc-modules-user
|
docker-compose up -d wfc-nginx wfc-gateway wfc-auth wfc-modules-system wfc-modules-user wfc-modules-payment
|
||||||
}
|
}
|
||||||
|
|
||||||
# 启动程序模块(后端)
|
# 启动程序模块(后端)
|
||||||
backend(){
|
backend(){
|
||||||
docker-compose up -d wfc-gateway wfc-auth wfc-modules-system wfc-modules-user
|
docker-compose up -d wfc-gateway wfc-auth wfc-modules-system wfc-modules-user wfc-modules-payment
|
||||||
}
|
}
|
||||||
|
|
||||||
# 启动程序模块(前端)
|
# 启动程序模块(前端)
|
||||||
|
|||||||
@@ -144,6 +144,17 @@ services:
|
|||||||
- "9300:9300"
|
- "9300:9300"
|
||||||
volumes:
|
volumes:
|
||||||
- ./wfc/uploadPath:/home/wfc/uploadPath
|
- ./wfc/uploadPath:/home/wfc/uploadPath
|
||||||
|
wfc-modules-payment:
|
||||||
|
container_name: wfc-modules-payment
|
||||||
|
build:
|
||||||
|
context: ./wfc/modules/payment
|
||||||
|
dockerfile: dockerfile
|
||||||
|
ports:
|
||||||
|
- "9306:9306"
|
||||||
|
depends_on:
|
||||||
|
- wfc-mysql
|
||||||
|
links:
|
||||||
|
- wfc-mysql
|
||||||
wfc-visual-monitor:
|
wfc-visual-monitor:
|
||||||
container_name: wfc-visual-monitor
|
container_name: wfc-visual-monitor
|
||||||
build:
|
build:
|
||||||
|
|||||||
15
docker/wfc/modules/payment/dockerfile
Normal file
15
docker/wfc/modules/payment/dockerfile
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
# 基础镜像
|
||||||
|
FROM openjdk:8-jre
|
||||||
|
# author
|
||||||
|
LABEL org.wfc.image.authors="wfc@wfc.org"
|
||||||
|
|
||||||
|
# 挂载目录
|
||||||
|
VOLUME /home/wfc
|
||||||
|
# 创建目录
|
||||||
|
RUN mkdir -p /home/wfc
|
||||||
|
# 指定路径
|
||||||
|
WORKDIR /home/wfc
|
||||||
|
# 复制jar文件到路径
|
||||||
|
COPY ./jar/wfc-modules-payment.jar /home/wfc/wfc-modules-payment.jar
|
||||||
|
# 启动系统服务
|
||||||
|
ENTRYPOINT ["java","-jar","wfc-modules-payment.jar"]
|
||||||
1
docker/wfc/modules/payment/jar/readme.txt
Normal file
1
docker/wfc/modules/payment/jar/readme.txt
Normal file
@@ -0,0 +1 @@
|
|||||||
|
<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϵͳģ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>õ<EFBFBD>jar<EFBFBD>ļ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>docker<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ӧ<EFBFBD>á<EFBFBD>
|
||||||
Reference in New Issue
Block a user