14 instantiations of ContainerRuntimeInfo
Aspire.Hosting (5)
src\Shared\ContainerRuntimeDetector.cs (5)
155return new ContainerRuntimeInfo 176return new ContainerRuntimeInfo 194return new ContainerRuntimeInfo 221return new ContainerRuntimeInfo 236return new ContainerRuntimeInfo
Aspire.Hosting.Tests (9)
Publishing\ContainerRuntimeDetectorTests.cs (9)
15new ContainerRuntimeInfo { Executable = "docker", Name = "Docker", IsInstalled = true, IsRunning = false, IsDefault = true }, 16new ContainerRuntimeInfo { Executable = "podman", Name = "Podman", IsInstalled = true, IsRunning = true, IsDefault = false } 29new ContainerRuntimeInfo { Executable = "docker", Name = "Docker", IsInstalled = false, IsRunning = false, IsDefault = true }, 30new ContainerRuntimeInfo { Executable = "podman", Name = "Podman", IsInstalled = true, IsRunning = false, IsDefault = false } 43new ContainerRuntimeInfo { Executable = "docker", Name = "Docker", IsInstalled = true, IsRunning = true, IsDefault = true }, 44new ContainerRuntimeInfo { Executable = "podman", Name = "Podman", IsInstalled = true, IsRunning = true, IsDefault = false } 65new ContainerRuntimeInfo { Executable = "podman", Name = "Podman", IsInstalled = true, IsRunning = true, IsDefault = false } 78new ContainerRuntimeInfo { Executable = "docker", Name = "Docker", IsInstalled = false, IsRunning = false, IsDefault = true }, 79new ContainerRuntimeInfo { Executable = "podman", Name = "Podman", IsInstalled = false, IsRunning = false, IsDefault = false }
17 references to ContainerRuntimeInfo
Aspire.Hosting (8)
Publishing\ContainerRuntimeResolver.cs (1)
78var detected = await ContainerRuntimeDetector.FindAvailableRuntimeAsync(logger: _logger, cancellationToken: cancellationToken).ConfigureAwait(false);
src\Shared\ContainerRuntimeDetector.cs (7)
108/// When a runtime is configured but not available, returns its info with <see cref="ContainerRuntimeInfo.IsInstalled"/> = false. 110public static async Task<ContainerRuntimeInfo?> FindAvailableRuntimeAsync(string? configuredRuntime = null, ILogger? logger = null, CancellationToken cancellationToken = default) 135public static async Task<ContainerRuntimeInfo> CheckRuntimeAsync(string executable, string name, bool isDefault, ILogger? logger = null, CancellationToken cancellationToken = default) 292public static ContainerRuntimeInfo? FindBestRuntime(IEnumerable<ContainerRuntimeInfo> results) 294ContainerRuntimeInfo? best = null; 295foreach (var candidate in results)
Aspire.Hosting.Tests (7)
DockerUtilsTests.cs (1)
18(_, _) => Task.FromException<ContainerRuntimeInfo?>(expectedException));
Publishing\ContainerRuntimeDetectorTests.cs (6)
19var best = ContainerRuntimeDetector.FindBestRuntime(runtimes); 33var best = ContainerRuntimeDetector.FindBestRuntime(runtimes); 47var best = ContainerRuntimeDetector.FindBestRuntime(runtimes); 55var best = ContainerRuntimeDetector.FindBestRuntime([]); 68var best = ContainerRuntimeDetector.FindBestRuntime(runtimes); 82var best = ContainerRuntimeDetector.FindBestRuntime(runtimes);
Aspire.Hosting.TestUtilities (2)
Utils\DockerUtils.cs (2)
38Func<string?, CancellationToken, Task<ContainerRuntimeInfo?>> runtimeDetector) 50var detected = Task.Run(