Browse Source
Don't consider it a fatal error when the container host is not accessible. (#1027)
For many use-cases there is no need to access the host.
philliphoff-arm64
Tom Deseyn
5 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
3 additions and
2 deletions
-
src/Microsoft.Tye.Hosting/DockerRunner.cs
|
|
|
@ -202,9 +202,10 @@ namespace Microsoft.Tye.Hosting |
|
|
|
var hostname = application.ContainerEngine.ContainerHost; |
|
|
|
if (hostname == null) |
|
|
|
{ |
|
|
|
_logger.LogError("Configuration doesn't allow containers to access services on the host."); |
|
|
|
_logger.LogWarning("Configuration doesn't allow containers to access services on the host."); |
|
|
|
|
|
|
|
throw new CommandException("Configuration doesn't allow containers to access services on the host."); |
|
|
|
// Set a value even though it won't be usable.
|
|
|
|
hostname = "host.docker.internal"; |
|
|
|
} |
|
|
|
|
|
|
|
var dockerImage = docker.Image ?? service.Description.Name; |
|
|
|
|