Skip to content

Commit

Permalink
Still failing. Debugging why
Browse files Browse the repository at this point in the history
  • Loading branch information
sburmanoctopus committed Dec 13, 2023
1 parent 9f3745f commit 1f0e3da
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@ public RunningTentacle(
public string HomeDirectory { get; }
public string ApplicationDirectory { get; }
public FileInfo TentacleExe { get; }
public string LogFilePath => Path.Combine(HomeDirectory, "Logs", "OctopusTentacle.txt");
public string LogFileDirectory => Path.Combine(HomeDirectory, "Logs");
public string LogFilePath => Path.Combine(LogFileDirectory, "OctopusTentacle.txt");

public async Task Start(CancellationToken cancellationToken)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -412,6 +412,12 @@ public async Task ShouldLogStartupDiagnosticsToInstanceLogFileOnly(TentacleConfi

var startingLogText = clientAndTentacle.RunningTentacle.ReadAllLogFileText();

//TODO: REMOVE
await Task.Delay(5000);
var startingLogText2 = clientAndTentacle.RunningTentacle.ReadAllLogFileText();

startingLogText2.Should().Be(startingLogText);

var (exitCode, stdout, stderr) = await RunCommandAndAssertExitsWithSuccessExitCode(tc, "show-thumbprint", $"--instance={clientAndTentacle.RunningTentacle.InstanceName}");

try
Expand Down Expand Up @@ -467,6 +473,13 @@ public async Task ShouldLogStartupDiagnosticsToInstanceLogFileOnly(TentacleConfi
Logger.Error($"Command StdOut: {Environment.NewLine}{stdout}");
Logger.Error($"Command StdErr: {Environment.NewLine}{stderr}");

//TODO: REMOVE?
var logFiles = Directory.EnumerateFiles(clientAndTentacle.RunningTentacle.LogFileDirectory);
foreach (var logFile in logFiles)
{
Logger.Error($"Found Log file: {logFile}");
}

throw;
}
}
Expand Down

0 comments on commit 1f0e3da

Please sign in to comment.