This allows the media to play at start, and the user can reasonably opt-in to listening. Many games do not have this sort of UI. For these, your best bet might be to write a little Javascript that ...
The first run creates ~/.next_index.json, generates a password and prints it once. The server then listens on http://localhost:8080.