We are having deployment problems using Aspose libraries in Docker containers. Parameters are
- App is .NET Core 2.1 web api
- Deployed to a Kubernetes cluster with an Linux Docker host, image “microsoft/dotnet:2.1-aspnetcore-runtime-alpine”
- Aspose.Total license expiry 20190216
- These libraries are referenced in a single project (versions checked by IlSpy):
a. Aspose.Pdf, Version=220.127.116.11,
b. Aspose.Cells, Version=18.104.22.168,
c. Aspose.Diagram, Version=22.214.171.124
d. Aspose.Slides, Version=126.96.36.199
e. Aspose.Words, Version=188.8.131.52
The symptoms are
• In development environment using IIS/kestrel the project builds and runs without errors
• All 5 of these dll’s are copied to the bin folder by msbuild
• When built in an Azure DevOps pipeline to make a Docker image these five are copied by Dockerfile and the dotnet build succeeds. Verified by copying the dll folder to the project root and examining the copy on linux.
• When deployed to the cluster, only 4 of the dlls appear in the app root. Aspose.PDF.dll is missing. Verified that the VS reference properties has Copy Local = Yes for all.
• When executed the program logs errors like so:
"Could not load file or assembly ‘Aspose.Pdf, Version=184.108.40.206, Culture=neutral, PublicKeyToken=716fcc553a201e56’. The system cannot find the file specified.”
• Manual copy of the missing dll to the Docker project root does not resolve the runtime error.
• Changing the case of the file to match assembly name (Aspose.PDF.dll->Aspose.Pdf.dll) does not resolve the error.