Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to deploy to Azure App service #697

Closed
stefankoserkov opened this issue Nov 25, 2019 · 2 comments
Closed

Unable to deploy to Azure App service #697

stefankoserkov opened this issue Nov 25, 2019 · 2 comments

Comments

@stefankoserkov
Copy link

stefankoserkov commented Nov 25, 2019

Hi,

Steps to reproduce:

  1. Create a new blank ASP.NET 4.7.2 project
  2. Install The ServiceStack 5.7.0 Nuget (which has a dependency on System.ComponentModel.Annotations)
  3. Deploy this project in GitHub
  4. In Azure, create an App Service which's Runtime stack is ASP.NET V4.7
  5. Once the App Service is created, go to its Deployment center and configure it to use the previously created Github repo
  • At this point, the build process will start, and it will fail with the following exception:

CSC : error CS1703: Multiple assemblies with equivalent identity have been imported: 'D:\home\site\repository\packages\System.ComponentModel.Annotations.4.4.1\lib\net461\System.ComponentModel.Annotations.dll' and 'D:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.7.2\Facades\System.ComponentModel.Annotations.dll'. Remove one of the duplicate references. [D:\home\site\repository\SitefinityWebApp.csproj] Failed exitCode=1, command="D:\Program Files (x86)\MSBuild\14.0\Bin\MSBuild.exe" "D:\home\site\repository\SitefinityWebApp.csproj" /nologo /verbosity:m /t:Build /t:pipelinePreDeployCopyAllFilesToOneFolder /p:_PackageTempDir="D:\local\Temp\8d76cd3c69223fa";AutoParameterizationWebConfigConnectionStrings=false;Configuration=Release;UseSharedCompilation=false /p:SolutionDir="D:\home\site\repository\.\\"

This issue was originally reproduced in Sitefinity CMS, however it is present in every .NET 4.7 app using the ServiceStack 5.7.0 Nuget package.

Thank you,
Stefan

@mythz
Copy link
Member

mythz commented Nov 25, 2019

This looks like a known dotnet SDK issue:
dotnet/sdk#1539 (comment)

There's a potential workaround in:
https://stackoverflow.com/a/44648397/85785

@mythz
Copy link
Member

mythz commented Nov 25, 2019

I've replaced it with a framework reference in this commit which is available from v5.7.1 that's now available on MyGet.

I'm assuming this should resolve it as it's no longer referencing the .NET Standard Library in .NET Framework builds. Please let me know if it doesn't resolve the issue.

@mythz mythz closed this as completed Nov 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants