-
Notifications
You must be signed in to change notification settings - Fork 7
/
start.sh
15 lines (13 loc) · 1.67 KB
/
start.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#!/bin/bash
if [ "$1" == "" ]
then
echo -e "\n-===!ERROR!===-\nPlease enter an API key as the first parameter!\n"
else
# Print name
echo -e "███████████████████████████████████████████████████████████████████████\n█▄─▄▄▀█─▄▄─█▄─▄─▀█─▄▄─███▄─▄▄▀█▄─▄▄─█▄─▄▄▀███─▄─▄─█▄─▄▄─██▀▄─██▄─▀█▀─▄█\n██─▄─▄█─██─██─▄─▀█─██─████─▄─▄██─▄█▀██─██─█████─████─▄█▀██─▀─███─█▄█─██\n▀▄▄▀▄▄▀▄▄▄▄▀▄▄▄▄▀▀▄▄▄▄▀▀▀▄▄▀▄▄▀▄▄▄▄▄▀▄▄▄▄▀▀▀▀▀▄▄▄▀▀▄▄▄▄▄▀▄▄▀▄▄▀▄▄▄▀▄▄▄▀\n"
echo -e "▀█▀ █▀█ ▄▀█ █ █▄░█ █ █▄░█ █▀▀ █▀█ █░░ ▄▀█ ▀█▀ █▀▀ █▀█ █▀█ █▀▄▀█\n░█░ █▀▄ █▀█ █ █░▀█ █ █░▀█ █▄█ █▀▀ █▄▄ █▀█ ░█░ █▀░ █▄█ █▀▄ █░▀░█\n"
# Generate SHA256 hash of API key
apiKey=$(echo -n "$1RoboRedTeamNotSoSecretSalt" | sha256sum | awk '{print $1}' | tr -d "\n")
#Start front- and backend server, as subprocesses
$(python3 ./frontend/tempWebServer.py 80) & $(python3 ./backend/backendServer.py 8855 $apiKey)
fi