VCMP-Docker/ea/dockerstart.sh
2024-09-09 20:45:50 +02:00

13 lines
369 B
Bash
Executable File

#!/bin/bash
mkdir -p /home/container/discord_bot /home/container/server
cd '/home/container/discord_bot'
npm install
pm2 start bot.js
cd /home/container/server
echo 'Starting server on' $PORT
# Using stdbuf to force unbuffered output since server is not directly connected to terminal and is buffering output
stdbuf -oL ./server -allow-server-runas-root -port $PORT