parent
cb76890814
commit
49e3882f1f
@ -0,0 +1,43 @@
|
|||||||
|
version: '2'
|
||||||
|
services:
|
||||||
|
kymks-mysql:
|
||||||
|
image: mysql:5.7
|
||||||
|
environment:
|
||||||
|
MYSQL_ROOT_PASSWORD: root
|
||||||
|
MYSQL_ROOT_HOST: '%'
|
||||||
|
TZ: Asia/Shanghai
|
||||||
|
restart: always
|
||||||
|
container_name: kykms-mysql
|
||||||
|
volumes:
|
||||||
|
- /home/docker/data/mysql:/var/lib/mysql
|
||||||
|
command:
|
||||||
|
--character-set-server=utf8mb4
|
||||||
|
--collation-server=utf8mb4_general_ci
|
||||||
|
--explicit_defaults_for_timestamp=true
|
||||||
|
--lower_case_table_names=1
|
||||||
|
--max_allowed_packet=128M
|
||||||
|
ports:
|
||||||
|
- 3306:3306
|
||||||
|
|
||||||
|
kymks-redis:
|
||||||
|
image: redis:5.0
|
||||||
|
ports:
|
||||||
|
- 6379:6379
|
||||||
|
restart: always
|
||||||
|
container_name: kykms-redis
|
||||||
|
|
||||||
|
kymks-ES:
|
||||||
|
image: elasticsearch:7.6.1
|
||||||
|
restart: always
|
||||||
|
hostname: kykms-ES
|
||||||
|
container_name: kykms-ES
|
||||||
|
volumes:
|
||||||
|
- /elasticsearch/data:/usr/share/elasticsearch/data
|
||||||
|
ports:
|
||||||
|
- 9200:9200
|
||||||
|
- 9300:9300
|
||||||
|
environment:
|
||||||
|
discovery.type: single-node
|
||||||
|
ES_JAVA_OPTS: "-Xms512m -Xmx512m"
|
||||||
|
cpuset-cpus: 1
|
||||||
|
m: 2G
|
@ -0,0 +1,37 @@
|
|||||||
|
yum install unzip -y;
|
||||||
|
wget http://qntest.weisi168.com/KM_community.zip
|
||||||
|
unzip KM_community.zip;
|
||||||
|
|
||||||
|
systemctl stop firewalld;
|
||||||
|
systemctl disable firewalld;
|
||||||
|
yum clean all;
|
||||||
|
yum make cache;
|
||||||
|
yum install docker -y;
|
||||||
|
yum install docker-compose -y;
|
||||||
|
systemctl start docker;
|
||||||
|
systemctl enable docker;
|
||||||
|
mkdir /elasticsearch;
|
||||||
|
mkdir /elasticsearch/data;
|
||||||
|
chmod 777 /elasticsearch/data;
|
||||||
|
chmod +x *.sh;
|
||||||
|
|
||||||
|
docker load -i kykms-mysql.tar;
|
||||||
|
docker load -i kykms-redis.tar;
|
||||||
|
docker load -i kykms-ES.tar;
|
||||||
|
docker-compose -f docker-compose-local.yml up -d;
|
||||||
|
|
||||||
|
yum install nginx -y;
|
||||||
|
mv /etc/nginx/nginx.conf /etc/nginx/nginx.conf.bak;
|
||||||
|
cp ./nginx.conf /etc/nginx/;
|
||||||
|
cp ./dist.zip /usr/share/nginx/html/;
|
||||||
|
cp ./simsun.ttc /usr/share/fonts/;
|
||||||
|
cd /usr/share/nginx/html;
|
||||||
|
unzip -o dist.zip;
|
||||||
|
systemctl enable nginx;
|
||||||
|
systemctl start nginx;
|
||||||
|
|
||||||
|
yum install java-1.8.0 -y;
|
||||||
|
yum install libreoffice.x86_64 -y;
|
||||||
|
cd -;
|
||||||
|
chmod +x *.sh;
|
||||||
|
./start.sh;
|
@ -0,0 +1,13 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
port=8080
|
||||||
|
|
||||||
|
pid=$(netstat -nlp | grep :$port | awk '{print $7}' | awk -F"/" '{ print $1 }');
|
||||||
|
|
||||||
|
if [ -n "$pid" ]; then
|
||||||
|
kill -9 $pid;
|
||||||
|
echo "KM service stopped."
|
||||||
|
fi
|
||||||
|
|
||||||
|
nohup java -jar ./jeecg-boot-module-system-2.4.5.jar catalina.out 2>&1 &
|
||||||
|
echo "KM service start completed."
|
@ -0,0 +1,6 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
#chkconfig:2345 80 90
|
||||||
|
#decription:autostart
|
||||||
|
|
||||||
|
nohup java -jar ./jeecg-boot-module-system-2.4.5.jar catalina.out 2>&1 &
|
||||||
|
echo "KM service start completed."
|
@ -0,0 +1,11 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
port=8080
|
||||||
|
|
||||||
|
pid=$(netstat -nlp | grep :$port | awk '{print $7}' | awk -F"/" '{ print $1 }');
|
||||||
|
|
||||||
|
if [ -n "$pid" ]; then
|
||||||
|
kill -9 $pid;
|
||||||
|
echo "KM service stopped."
|
||||||
|
fi
|
||||||
|
|
Loading…
Reference in new issue