rm ignore file
This commit is contained in:
parent
0464733099
commit
aad71a6f42
16
did-server/docker/Dockerfile
Normal file
16
did-server/docker/Dockerfile
Normal file
@ -0,0 +1,16 @@
|
||||
FROM ehlxr/jre8-alpine:latest
|
||||
MAINTAINER ehlxr <ehlxr.me@gmail.com>
|
||||
|
||||
WORKDIR /opt
|
||||
|
||||
ARG SERVER_NAME
|
||||
ENV SERVER_NAME=${SERVER_NAME}
|
||||
|
||||
COPY start.sh /opt/start.sh
|
||||
COPY ${SERVER_NAME}*.jar /opt/
|
||||
|
||||
RUN chmod -R 755 /opt/
|
||||
|
||||
|
||||
EXPOSE 16830 16831
|
||||
ENTRYPOINT ["/opt/start.sh"]
|
19
did-server/docker/start.sh
Executable file
19
did-server/docker/start.sh
Executable file
@ -0,0 +1,19 @@
|
||||
#!/bin/sh
|
||||
|
||||
#HOSTNAME=`hostname | cut -c1-18`
|
||||
LOGS_DIR="/data/logs"
|
||||
|
||||
if [ ! -d ${LOGS_DIR} ]; then
|
||||
mkdir -p ${LOGS_DIR}
|
||||
fi
|
||||
STDOUT_FILE=${LOGS_DIR}/${SERVER_NAME}.log
|
||||
|
||||
JAVA_OPTS=" -Duser.timezone=\"Asia/Shanghai\" -Djava.awt.headless=true -Djava.net.preferIPv4Stack=true -Dfile.encoding=UTF8"
|
||||
|
||||
JAVA_MEM_OPTS=" -server -Xmx${XMX:-512m} -Xms${XMS:-128m} -Xss256k -XX:+DisableExplicitGC -XX:+UseConcMarkSweepGC \
|
||||
-XX:+CMSParallelRemarkEnabled -XX:+UseCMSCompactAtFullCollection -XX:LargePageSizeInBytes=${LargePageSize:-4m} \
|
||||
-XX:+UseFastAccessorMethods -XX:+UseCMSInitiatingOccupancyOnly -XX:CMSInitiatingOccupancyFraction=70 "
|
||||
|
||||
echo "Starting the ${SERVER_NAME} ...\c"
|
||||
#java -jar ${JAVA_OPTS} ${JAVA_MEM_OPTS} ./${SERVER_NAME}-*.jar > ${STDOUT_FILE} 2>&1
|
||||
java -jar ${JAVA_OPTS} ${JAVA_MEM_OPTS} ./${SERVER_NAME}-*.jar | tee -a ${STDOUT_FILE} 2>&1
|
Loading…
Reference in New Issue
Block a user