Updated to latest moonlight and mooncore version. Done refactoring to async scheme and other changes. Recreated database migrations and cleaned models
This commit is contained in:
@@ -57,17 +57,17 @@ public class DockerConsole : IConsole
|
||||
{
|
||||
var containerName = string.Format(DockerConstants.RuntimeNameTemplate, Context.Configuration.Id);
|
||||
|
||||
await AttachToContainer(containerName);
|
||||
await AttachToContainerAsync(containerName);
|
||||
}
|
||||
|
||||
public async Task AttachInstallationAsync()
|
||||
{
|
||||
var containerName = string.Format(DockerConstants.InstallationNameTemplate, Context.Configuration.Id);
|
||||
|
||||
await AttachToContainer(containerName);
|
||||
await AttachToContainerAsync(containerName);
|
||||
}
|
||||
|
||||
private async Task AttachToContainer(string containerName)
|
||||
private async Task AttachToContainerAsync(string containerName)
|
||||
{
|
||||
var cts = new CancellationTokenSource();
|
||||
|
||||
@@ -171,17 +171,17 @@ public class DockerConsole : IConsole
|
||||
{
|
||||
var containerName = string.Format(DockerConstants.RuntimeNameTemplate, Context.Configuration.Id);
|
||||
|
||||
await FetchFromContainer(containerName);
|
||||
await FetchFromContainerAsync(containerName);
|
||||
}
|
||||
|
||||
public async Task FetchInstallationAsync()
|
||||
{
|
||||
var containerName = string.Format(DockerConstants.InstallationNameTemplate, Context.Configuration.Id);
|
||||
|
||||
await FetchFromContainer(containerName);
|
||||
await FetchFromContainerAsync(containerName);
|
||||
}
|
||||
|
||||
private async Task FetchFromContainer(string containerName)
|
||||
private async Task FetchFromContainerAsync(string containerName)
|
||||
{
|
||||
var logStream = await DockerClient.Containers.GetContainerLogsAsync(containerName, true, new()
|
||||
{
|
||||
|
||||
@@ -104,7 +104,7 @@ public class DockerInstallation : IInstallation
|
||||
// Docker image
|
||||
await Reporter.StatusAsync("Downloading docker image");
|
||||
|
||||
await ImageService.Download(data.DockerImage, async status => { await Reporter.StatusAsync(status); });
|
||||
await ImageService.DownloadAsync(data.DockerImage, async status => { await Reporter.StatusAsync(status); });
|
||||
|
||||
await Reporter.StatusAsync("Downloaded docker image");
|
||||
|
||||
@@ -159,7 +159,7 @@ public class DockerInstallation : IInstallation
|
||||
}
|
||||
}
|
||||
|
||||
public async Task<IAsyncDisposable> SubscribeExited(Func<int, ValueTask> callback)
|
||||
public async Task<IAsyncDisposable> SubscribeExitedAsync(Func<int, ValueTask> callback)
|
||||
=> await ExitEventSource.SubscribeAsync(callback);
|
||||
|
||||
public async Task RestoreAsync()
|
||||
|
||||
@@ -96,7 +96,7 @@ public class DockerRuntime : IRuntime
|
||||
// Docker image
|
||||
await Reporter.StatusAsync("Downloading docker image");
|
||||
|
||||
await ImageService.Download(
|
||||
await ImageService.DownloadAsync(
|
||||
Context.Configuration.DockerImage,
|
||||
async status => { await Reporter.StatusAsync(status); }
|
||||
);
|
||||
@@ -152,7 +152,7 @@ public class DockerRuntime : IRuntime
|
||||
}
|
||||
}
|
||||
|
||||
public async Task<IAsyncDisposable> SubscribeExited(Func<int, ValueTask> callback)
|
||||
public async Task<IAsyncDisposable> SubscribeExitedAsync(Func<int, ValueTask> callback)
|
||||
=> await ExitEventSource.SubscribeAsync(callback);
|
||||
|
||||
public async Task RestoreAsync()
|
||||
|
||||
Reference in New Issue
Block a user