It was the Swiss outfit who started much the better of both sides and goalkeeper Alan Mannus was handed his first test in tipping a goal-bound effort over the bar on 23 minutes.
The Scottish Premiership club flirted with concession once again minutes later, as Luzern fired against the post to keep St Johnstone on level terms by the slimmest of margins.
Mackay then produced a crucial goal-line clearance before the break to allow the Scots to edge ahead just two minutes into the second half, with Steven MacLean stroking home for the Scottish Cup winners.
The visitors continued in the same vein and can count themselves unfortunate not to be taking two away goals back to McDiarmid Park next week, as Mackay saw his effort hacked off the line before MacLean fired wide following a defensive mix-up.
They proved costly misses, however, as Marco Schuewly fired the hosts back on level terms with 23 minutes remaining.
Luzern wasted a good opportunity to nick victory on 81 minutes but Wright's men survived to earn a slender first-leg advantage. body check tags ::