.OnErrorDelegate errorHandler,
@@ -101,15 +98,19 @@ public async Task StartAsync(string binPath,
RedirectStandardOutput = true,
},
};
+ // TODO: maybe we should change the log format in the inner binary
+ // to something without a timestamp
+ var outLogger = Log.ForContext("SourceContext", "coder-vpn.exe[OUT]");
+ var errLogger = Log.ForContext("SourceContext", "coder-vpn.exe[ERR]");
_subprocess.OutputDataReceived += (_, args) =>
{
if (!string.IsNullOrWhiteSpace(args.Data))
- _logger.LogDebug("OUT: {Data}", args.Data);
+ outLogger.Debug("{Data}", args.Data);
};
_subprocess.ErrorDataReceived += (_, args) =>
{
if (!string.IsNullOrWhiteSpace(args.Data))
- _logger.LogDebug("ERR: {Data}", args.Data);
+ errLogger.Debug("{Data}", args.Data);
};
// Pass the other end of the pipes to the subprocess and dispose
pFad - Phonifier reborn
Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.
Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.
Alternative Proxies:
Alternative Proxy
pFad Proxy
pFad v3 Proxy
pFad v4 Proxy