mirror of
https://github.com/outbackdingo/firezone.git
synced 2026-01-27 10:18:54 +00:00
fix(gui-client): initialise logger one layer up (#9111)
Initialising the logger as part of the `open` function causes a flaky test in case there is already another logger initialised. Fixes: #9096
This commit is contained in:
@@ -70,6 +70,8 @@ fn main() -> anyhow::Result<()> {
|
||||
// If we already tried to elevate ourselves, don't try again
|
||||
Some(Cmd::Elevated) => run_gui(config),
|
||||
Some(Cmd::OpenDeepLink(deep_link)) => {
|
||||
firezone_gui_client::logging::setup_stdout()?;
|
||||
|
||||
let rt = tokio::runtime::Runtime::new()?;
|
||||
if let Err(error) = rt.block_on(deep_link::open(&deep_link.url)) {
|
||||
tracing::error!("Error in `OpenDeepLink`: {error:#}");
|
||||
|
||||
@@ -86,7 +86,6 @@ impl Server {
|
||||
|
||||
pub async fn open(url: &url::Url) -> Result<()> {
|
||||
crate::logging::setup_stdout()?;
|
||||
|
||||
let path = sock_path()?;
|
||||
let mut stream = UnixStream::connect(&path).await?;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user