- OS must support
nc
command to check servers withnc
. - Python Virtual Environment
- Clone this part of the repository
- Create a python3 virtual environment using
python3 -m venv env
- Activate the environment
source env/bin/activate
- Install requirements
pip install -r requirements.txt
- Create a
.env
file with the format in example files - Add an entry to crontab for the necessary interval
- Fetches challenge information from CTFd
- Looks into
connection name
within CTFd challenges - If it starts with
http
orhttps
it is added to the health check viahttp
- If it starts with
nc
it is checked by using thenc -nz
command
TELEGRAM_TOKEN="" # Telegram bot token
TELEGRAM_CHAT_ID="" # Telegram group chat id
CTFD_URL="" # CTFd URL
CTFD_API_KEY="" # API Key to access the challenges
This line will ensure that the script runs every 10 minutes and log the stdout
to /root/health_check/status.log
*/10 * * * * { source /root/health_check/env/bin/activate && python3 /root/health_check/app.py && deactivate; } >> /root/health_check/status.log 2>&1
- Status 200 on websites
nc
connectivity
- Testing solution scripts to see if challenges work
- More methods of checking if the server is up