Phantom pdf on Azure in ASP.NET Core

僤鯓⒐⒋嵵緔 提交于 2019-12-08 17:06:49

phantomjs and other pdf rendering won't work in Azure App service running on default Windows Server. However you can now use Azure App service running on linux where jsreport nicely works.

You just need to switch to Web App on Linux when creating new App Service and use node based container. Then you can use docker hub to download an image with jsreport right into the Web App. The simplest is to use official jsreport image but it is easy to use also your own.

Links
Tutorial how run jsreport on Azure Web App on linux
jsreport official docker image

I'm aware I didn't answer how to actually run it in the same app as asp.net core. I don't know how to do that currently, but I suggest you to run asp.net application and jsreport in separate apps. You can easily invoke jsreport rendering through REST. This could also improve your architecture design.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!