winbox/entrypoint.sh
merith-tk 680ee425d3
All checks were successful
Build Docker Image on Commit / build-and-publish (push) Successful in 42s
Build and Publish Docker Image on Tag / build-and-publish (push) Successful in 40s
auto restart winbox
2025-06-06 18:27:47 +01:00

19 lines
No EOL
484 B
Bash

#!/bin/bash
# Wait until internet is available
while ! ping -c1 1.1.1.1 &>/dev/null; do
echo "Waiting for internet connection..."
sleep 5
done
if [ ! -f "/winbox64.exe" ]; then
echo "Winbox executable not found in /data. Downloading..."
wget -O /winbox64.exe https://download.mikrotik.com/routeros/winbox/3.42/winbox64.exe
fi
while true; do
echo "Starting Winbox..."
wine64 /winbox64.exe
echo "Winbox closed. Restarting in 3 seconds..."
sleep 3
done