Azure / service-fabric-mesh-preview

Service Fabric Mesh is the Service Fabric's serverless offering to enable developers to deploy containerized applications without managing infrastructure. Service Fabric Mesh , aka project “SeaBreeze” is currently available in private preview. This repository will be used for tracking bugs/feature requests as GitHub issues and for maintaining the latest documentation.
MIT License
83 stars 10 forks source link

Unable to load the service index for source https://api.nuget.org/v3/index.json #367

Closed keshavraja closed 5 years ago

keshavraja commented 5 years ago

I have created a new application in Service Fabric Mesh and added dotnet core 2.2 Web API project. In debug mode everything works properly. But in release mode, I am getting the following error

Restoring packages for C:\src\Web1\Web1.csproj... C:\Program Files\dotnet\sdk\2.1.503\NuGet.targets(114,5): error : Unable to load the service index for source https://api.nuget.org/v3/index.json. [C:\src\Web1\Web1.csproj] C:\Program Files\dotnet\sdk\2.1.503\NuGet.targets(114,5): error : No such host is known [C:\src\Web1\Web1.csproj] The command 'cmd /S /C dotnet restore Web1/Web1.csproj' returned a non-zero code: 1 SFA1003 : Building dockerfile 'C:\Users\keshav.k\source\repos\Application1\Web1\Dockerfile' failed.

Normal Web API project(without service fabric mesh) with docker support works fine in release mode.

andreujuanc commented 5 years ago

There is a known error on the network side of things, it might not be this, but it can be worth give it a try.

Assuming you are on windows, the easy way to know if this is the case is in your dockerfile add: RUN ping google.com And if it cannot find the host then it's most certainly this issue. Then execute this powershell: Get-NetIPInterface and see if your WIFI & Ethernet adapters are low enough. Somehow docker for windows (which mesh relies on) does not goes out for dns if the other is different.

So in short, give 'Wi-Fi' and 'Ethernet' adapters a low metric value.

keshavraja commented 5 years ago

@andre

There is a known error on the network side of things, it might not be this, but it can be worth give it a try.

Assuming you are on windows, the easy way to know if this is the case is in your dockerfile add: RUN ping google.com And if it cannot find the host then it's most certainly this issue. Then execute this powershell: Get-NetIPInterface and see if your WIFI & Ethernet adapters are low enough. Somehow docker for windows (which mesh relies on) does not goes out for dns if the other is different.

So in short, give 'Wi-Fi' and 'Ethernet' adapters a low metric value.

Sorry for the late reply, My colleagues who are on the same network were not getting the same error. So I re-installed Visual Studio, Docker and Service Fabric Mesh and everything are working properly.