Fix headless mode (#12960)

This was broken by two things:
1. A merge conflict in the install.sh script leading to bad sh syntax
2. A return removed by accident when we refactored main

Release Notes:

- N/A
e2cfbc54adConrad Irwin committed on 6/13/2024, 1:59:28 PM· committed by GitHubparent0a13b9e
2 files changedLine totals unavailable