TT#83753 Port status server to py3

The /usr/bin/python symlink/binary no longer exists in recent
Grml-Sipwise ISOs and python3 doesn't ship SimpleHTTPServer but
http.server instead.

Change-Id: I6677e8a416b142034d99d5b1d2b11ba74d87a6ec
(cherry picked from commit 862fb155f0)
changes/07/41807/1
Michael Prokop 5 years ago
parent 8aefdb2511
commit d3df314b3b

@ -72,12 +72,12 @@ enable_deploy_status_server() {
mkdir -p "${STATUS_DIRECTORY}"
# get rid of already running process
PID=$(pgrep -f 'python.*SimpleHTTPServer') || true
PID=$(pgrep -f 'python3.*http.server') || true
[ -n "$PID" ] && kill "$PID"
(
cd "${STATUS_DIRECTORY}"
python -m SimpleHTTPServer 4242 >/tmp/status_server.log 2>&1 &
python3 -m http.server 4242 >/tmp/status_server.log 2>&1 &
)
}

Loading…
Cancel
Save