Wiki > Flood
A random port number between 10000 and 65535 is needed and will be used to access Flood once installation is complete. The port number
21508 has automatically been generated and will be used throughout this article, but can be changed if needed.
SSH into the server following the instructions found here /wiki/ssh
Clone the Flood git repository on to your slot
git clone https://github.com/jesec/flood.git
Change to the Flood directory
Build and install Flood. This process may take some time to complete.
npm install; npm run build
Launch Flood in a background screen session on your random port
screen -dmS flood npm start -- --host 0.0.0.0 --port 21508
Access Flood at http://server.whatbox.ca:21508. Choose a username and password you will use to access Flood. For the socket path, enter
Setup Flood to automatically restart should the server reboot for any reason.
Use nano to create the script file and enter the text below.
nano -w ~/flood_restart.cron
#!/bin/bash if pgrep -fx "screen -dmS flood_server ~/flood/flood npm start -- --host 0.0.0.0 --port 21508 > /dev/null then echo "Flood is running." else echo "Flood is not running, starting Flood" screen -dmS flood_server ~/flood/flood npm start -- --host 0.0.0.0 --port 21508 fi exit
Save the file with Ctrl+x and if it prompts press the "y" and Enter to accept overwriting.
Make the script executable.
chmod +x ~/flood_restart.cron
Open your crontab.
EDITOR=nano crontab -e
Enter the following text
@reboot /home/user/flood_restart.cron >/dev/null 2>&1 */5 * * * * /home/user/flood_restart.cron >/dev/null 2>&1
Save the crontab with Ctrl+x and the "y" and Enter to accept overwriting.