未验证 提交 5e65788f 编写于 作者: A avalon5666 提交者: GitHub

Add scaling & ui dockerfile (#5639)

* Add scaling distribution dockerfile

* Scaling bin support load third part jar from ext-lib dictory

* Add sharding ui dockerfile
Co-authored-by: Navalon566 <avalon566@163.com>
上级 fe2f8054
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
FROM java:8
MAINTAINER ShardingSphere "dev@shardingsphere.apache.org"
ENV CURRENT_VERSION 4.1.1
ENV APP_NAME apache-shardingsphere
ENV MODULE_NAME sharding-scaling
ENV LOCAL_PATH /opt/sharding-scaling
RUN wget https://dist.apache.org/repos/dist/release/shardingsphere/${CURRENT_VERSION}/${APP_NAME}-${CURRENT_VERSION}-${MODULE_NAME}-bin.tar.gz && \
tar -xzvf ${APP_NAME}-${CURRENT_VERSION}-${MODULE_NAME}-bin.tar.gz && \
mv ${APP_NAME}-${CURRENT_VERSION}-${MODULE_NAME}-bin ${LOCAL_PATH} && \
rm -f ${APP_NAME}-${CURRENT_VERSION}-${MODULE_NAME}-bin.tar.gz
ENTRYPOINT ${LOCAL_PATH}/bin/start.sh ${PORT} && tail -f ${LOCAL_PATH}/logs/stdout.log
......@@ -21,7 +21,7 @@ cd %~dp0
set SERVER_NAME=Sharding-Scaling
set CLASS_PATH="..\conf;.;..;..\lib\*"
set CLASS_PATH="..\conf;.;..;..\lib\*;..\ext-lib\*"
echo The classpath is %CLASS_PATH%
......
......@@ -28,6 +28,7 @@ if [ ! -d ${LOGS_DIR} ]; then
fi
STDOUT_FILE=${LOGS_DIR}/stdout.log
EXT_LIB=${DEPLOY_DIR}/ext-lib
PIDS=`ps -ef | grep java | grep "$DEPLOY_DIR" | grep -v grep | awk '{print $2}'`
if [ -n "$PIDS" ]; then
......@@ -36,7 +37,7 @@ if [ -n "$PIDS" ]; then
exit 1
fi
CLASS_PATH=.:${DEPLOY_DIR}/conf:${DEPLOY_DIR}/lib/*
CLASS_PATH=.:${DEPLOY_DIR}/conf:${DEPLOY_DIR}/lib/*:${EXT_LIB}/*
JAVA_OPTS=" -Djava.awt.headless=true -Djava.net.preferIPv4Stack=true "
JAVA_MEM_OPTS=" -server -Xmx2g -Xms2g -Xmn1g -Xss256k -XX:+DisableExplicitGC -XX:+UseConcMarkSweepGC -XX:+CMSParallelRemarkEnabled -XX:LargePageSizeInBytes=128m -XX:+UseFastAccessorMethods -XX:+UseCMSInitiatingOccupancyOnly -XX:CMSInitiatingOccupancyFraction=70 "
......
......@@ -15,7 +15,7 @@
# limitations under the License.
#
# port: 8888
# blockQueueSize: 10000
# pushTimeout: 1000
# workerThread: 30
port: 8888
blockQueueSize: 10000
pushTimeout: 1000
workerThread: 30
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
FROM java:8
MAINTAINER ShardingSphere "dev@shardingsphere.apache.org"
ENV CURRENT_VERSION 4.1.1
ENV APP_NAME apache-shardingsphere
ENV MODULE_NAME shardingsphere-ui
ENV LOCAL_PATH /opt/shardingsphere-ui
RUN wget https://dist.apache.org/repos/dist/release/shardingsphere/shardingsphere-ui-${CURRENT_VERSION}/${APP_NAME}-${CURRENT_VERSION}-${MODULE_NAME}-bin.tar.gz && \
tar -xzvf ${APP_NAME}-${CURRENT_VERSION}-${MODULE_NAME}-bin.tar.gz && \
mv ${APP_NAME}-${CURRENT_VERSION}-${MODULE_NAME}-bin ${LOCAL_PATH} && \
rm -f ${APP_NAME}-${CURRENT_VERSION}-${MODULE_NAME}-bin.tar.gz
ENTRYPOINT ${LOCAL_PATH}/bin/start.sh ${PORT} && tail -f ${LOCAL_PATH}/logs/stdout.log
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册