Fix issues and update config.example.env
This commit is contained in:
parent
b7e43cf437
commit
80a4bc4f14
2 changed files with 40 additions and 8 deletions
|
@ -1,5 +1,8 @@
|
|||
# MCServerDocker configuration file
|
||||
|
||||
##################
|
||||
# Server options #
|
||||
##################
|
||||
# ENFORCE_FRESH_CACHES
|
||||
## Cleans all caches on startup, useful if you experience issues.
|
||||
MCSD_ENFORCE_FRESH_CACHES=false
|
||||
|
@ -12,17 +15,46 @@ MCSD_FORCE_UPGRADE=true
|
|||
# Disables all datapacks
|
||||
MCSD_SAFEMODE=false
|
||||
|
||||
# AUTO_RESTART
|
||||
## Restarts the server automatically if it exits
|
||||
MCSD_AUTO_RESTART=true
|
||||
|
||||
#################
|
||||
# MCSD features #
|
||||
#################
|
||||
# CLEAN_LOGS
|
||||
# Removes all log files on startup (restarts are not affected)
|
||||
MCSD_CLEAN_LOGS=true
|
||||
|
||||
# AUTO_RESTART
|
||||
## Restarts the server automatically if it exits
|
||||
MCSD_AUTO_RESTART=true
|
||||
|
||||
#################
|
||||
# Memory limits #
|
||||
#################
|
||||
# MIN_MEMORY
|
||||
## The minimum amount of memory Minecraft uses
|
||||
## Set this to $MCSD_MEMORY_MAX if you want maximum performance
|
||||
MCSD_MEMORY_MIN=2048M
|
||||
|
||||
# MAX_MEMORY
|
||||
## The maximum amount of memory Minecraft should use
|
||||
## Note: The java process WILL use more memory than you specify here,
|
||||
## as the JVM does not include itself in this limit here.
|
||||
MCSD_MAX_MEMORY=2048M
|
||||
|
||||
########
|
||||
# Java #
|
||||
########
|
||||
# JAVA_VERSION
|
||||
## Minecraft version | Java version
|
||||
## <= 1.16 | 8
|
||||
## <= 1.16 | 11 (may increase performance)
|
||||
## >= 1.17 | 17
|
||||
MCSD_JAVA_VERSION=17
|
||||
|
||||
# OPTIMIZED_FLAGS
|
||||
## Applies a modified variant of Aikar's Flags
|
||||
MCSD_OPTIMIZED_FLAGS=true
|
||||
|
||||
# GARBAGECOLLECTOR
|
||||
## Configures the garbage collector
|
||||
## Supported are: G1GC, ZGC
|
||||
MCSD_GARBAGECOLLECTOR=G1GC
|
||||
|
|
|
@ -66,11 +66,11 @@ function initialize() {
|
|||
export "MCSD_CLEAN_LOGS=false"
|
||||
fi
|
||||
# Memory limits
|
||||
if [ -n "${MCSD_MEMORY_MIN}" ]; then
|
||||
if [ -z "${MCSD_MEMORY_MIN}" ]; then
|
||||
echo ":: Error: No memory limit supplied to \$MCSD_MEMORY_MIN"
|
||||
exit 1
|
||||
fi
|
||||
if [ -n "${MCSD_MEMORY_MAX}" ]; then
|
||||
if [ -z "${MCSD_MEMORY_MAX}" ]; then
|
||||
echo ":: Error: No memory limit supplied to \$MCSD_MEMORY_MAX"
|
||||
exit 1
|
||||
fi
|
||||
|
@ -191,7 +191,7 @@ function main() {
|
|||
run
|
||||
# Restart server if enabled
|
||||
if [ "${SHUTDOWN}" == "true" ]; then
|
||||
echo ":: Ending execution"
|
||||
echo ":: Ending execution (SHUTDOWN=true)"
|
||||
exit 0
|
||||
fi
|
||||
case "${MCSD_AUTO_RESTART}" in
|
||||
|
@ -200,7 +200,7 @@ function main() {
|
|||
run
|
||||
;;
|
||||
"false")
|
||||
echo ":: Ending execution"
|
||||
echo ":: Ending execution (MCSD_AUTO_RESTART=false)"
|
||||
exit 0
|
||||
;;
|
||||
*)
|
||||
|
|
Loading…
Reference in a new issue