Skip to content

Commit

Permalink
feat: added configurable WOLF_PULSE_CONTAINER_TIMEOUT_MS
Browse files Browse the repository at this point in the history
  • Loading branch information
ABeltramo committed Jun 29, 2024
1 parent b21a5a8 commit 1d8f181
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/moonlight-server/wolf.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,8 @@ std::optional<AudioServer> setup_audio_server(const std::string &runtime_dir) {
}
})");
if (container && docker_api.start_by_id(container.value().id)) {
std::this_thread::sleep_for(1000ms); // TODO: configurable? Better way of knowing when ready?
auto ms = std::stoi(utils::get_env("WOLF_PULSE_CONTAINER_TIMEOUT_MS", "2000"));
std::this_thread::sleep_for(std::chrono::milliseconds(ms)); // TODO: Better way of knowing when ready?
return {{.server = audio::connect(fmt::format("{}/pulse-socket", runtime_dir)), .container = container}};
}
}
Expand Down

0 comments on commit 1d8f181

Please sign in to comment.