kopia lustrzana https://github.com/OpenDroneMap/WebODM
Add --worker-memory parameter
rodzic
9bfdf9c320
commit
93704420c6
|
@ -0,0 +1,4 @@
|
||||||
|
version: '2.1'
|
||||||
|
services:
|
||||||
|
worker:
|
||||||
|
mem_limit: ${WO_WORKER_MEMORY}
|
13
webodm.sh
13
webodm.sh
|
@ -135,6 +135,12 @@ case $key in
|
||||||
export WO_SETTINGS
|
export WO_SETTINGS
|
||||||
shift # past argument
|
shift # past argument
|
||||||
shift # past value
|
shift # past value
|
||||||
|
;;
|
||||||
|
--worker-memory)
|
||||||
|
WO_WORKER_MEMORY="$2"
|
||||||
|
export WO_WORKER_MEMORY
|
||||||
|
shift # past argument
|
||||||
|
shift # past value
|
||||||
;;
|
;;
|
||||||
*) # unknown option
|
*) # unknown option
|
||||||
POSITIONAL+=("$1") # save it in an array for later
|
POSITIONAL+=("$1") # save it in an array for later
|
||||||
|
@ -178,6 +184,8 @@ usage(){
|
||||||
echo " --detached Run WebODM in detached mode. This means WebODM will run in the background, without blocking the terminal (default: disabled)"
|
echo " --detached Run WebODM in detached mode. This means WebODM will run in the background, without blocking the terminal (default: disabled)"
|
||||||
echo " --gpu Use GPU NodeODM nodes (Linux only) (default: disabled)"
|
echo " --gpu Use GPU NodeODM nodes (Linux only) (default: disabled)"
|
||||||
echo " --settings Path to a settings.py file to enable modifications of system settings (default: None)"
|
echo " --settings Path to a settings.py file to enable modifications of system settings (default: None)"
|
||||||
|
echo " --worker-memory Maximum amount of memory allocated for the worker process (default: unlimited)"
|
||||||
|
|
||||||
exit
|
exit
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -348,6 +356,7 @@ start(){
|
||||||
echo "Celery Broker: $WO_BROKER"
|
echo "Celery Broker: $WO_BROKER"
|
||||||
echo "Default Nodes: $WO_DEFAULT_NODES"
|
echo "Default Nodes: $WO_DEFAULT_NODES"
|
||||||
echo "Settings: $WO_SETTINGS"
|
echo "Settings: $WO_SETTINGS"
|
||||||
|
echo "Worker memory limit: $WO_WORKER_MEMORY"
|
||||||
echo "================================"
|
echo "================================"
|
||||||
echo "Make sure to issue a $0 down if you decide to change the environment."
|
echo "Make sure to issue a $0 down if you decide to change the environment."
|
||||||
echo ""
|
echo ""
|
||||||
|
@ -418,6 +427,10 @@ start(){
|
||||||
command+=" -f docker-compose.settings.yml"
|
command+=" -f docker-compose.settings.yml"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [ ! -z "$WO_WORKER_MEMORY" ]; then
|
||||||
|
command+=" -f docker-compose.worker-memory.yml"
|
||||||
|
fi
|
||||||
|
|
||||||
command="$command up"
|
command="$command up"
|
||||||
|
|
||||||
if [[ $detached = true ]]; then
|
if [[ $detached = true ]]; then
|
||||||
|
|
Ładowanie…
Reference in New Issue