This repository has been archived on 2022-06-10. You can view files and clone it, but cannot push or open issues or pull requests.
mydraftcc-nodejs-server/server/start.sh

21 lines
468 B
Bash
Executable File

#!/bin/bash
## those dirs are needed
pwd
for dir in "data logs"
do
if [ -d "$dir" ];then mkdir "$dir";fi
done
# Where is node or nodejs (alpine <> debian)
NODEJS="/usr/bin/nodejs"
if [ ! -f "$NODEJS" ];then
NODEJS="/usr/bin/node"
fi
## Start application
# Parameters
# listening ip address
# listening port
# Storage: maximum size of the drawing file
# (2Mo : 2 * 1024 * 1024) = 2097152
IPADDRESS=0.0.0.0 PORT=4000 JSONMAXSIZE=2097152 $NODEJS app.js