Reputation: 61
hi friends
While exploring the dotnet core with Linux, jenkins and docker I've face the build issue which gives the error in title "/usr/share/dotnet/sdks/microsoft.docker.sdk/sdk/sdk.props was not found". Because of this build is getting failed.
I checked the dotnet installation location to see that it was not available.
I know that this particular file will be available in this location on Windows with VS 2017 installed C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\Sdks\Microsoft.Docker.Sdk\Sdk
how to get this installed or make it available on the linux box so that build can run smoothly.
PFA image which was run from the terminal for re-producing issue.
Any help will be much appreciated.
Upvotes: 0
Views: 585
Reputation: 100751
This is a known issue, see its issue on GitHub for details and updates. The problem is that a closed source component in VS is not part of the .net CLI.
The current workarounds are:
Copy the Microsoft.Docker.Sdk
folder from your VS installation to the CLI version you are using. For example from
C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\Sdks\Microsoft.Docker.Sdk
into the folder
/usr/local/share/dotnet/sdk/1.0.4/Sdks/
If the Microsoft.Docker.Sdk
folder contains more than the Sdk
subfolder, delete those other folders (e.g. build
, tools
).
Create a second solution containing all projects except for the docker project (.dcproj
) and only build that from the CLI.
Upvotes: 2