uploaded.sh 316 B

123456789101112131415161718
  1. #!/bin/bash
  2. CURRENT_PATH=$(pwd);
  3. ROOT_PATH=$(cd `dirname $0`/; pwd);
  4. RUN_PATH=${ROOT_PATH}
  5. echo $1
  6. TARGET=$1
  7. cd ${RUN_PATH}
  8. pwd
  9. if [[ $TARGET = "gateway" ]]
  10. then
  11. npx pm2 start --hp ${RUN_PATH} ${RUN_PATH}/pm2.json
  12. elif [[ $TARGET = "gateway-all" ]]
  13. then
  14. npx pm2 start --hp ${RUN_PATH} ${RUN_PATH}/pm2.json
  15. fi