Image manipulation using Node.js on Azure website

左心房为你撑大大i 提交于 2020-01-16 04:53:20

问题


I'm developing a web project using Node.js where users can set their profile image by uploading it to the server.

I need to perform basic manipulation on those images (resize and crop), and then store them into a blob.

I usually use GraphicsMagic or ImageMagick to achieve this kind of tasks, but I want to publish this project on Microsoft Azure website.

Is there a known and safe way to manipulate images serverside into an Azure website using Node.js?


回答1:


You can use node modules with Azure Websites. However you cannot install any third party apps on the Web Sites (thus no ImageMagick or Graphics Magic).

Looking out in the wild, you may find some native node modules that does not require external components to manipulate images like the lwip and probably some more. Just find your module that is not dependent on external third party libraries and is fully self contained.




回答2:


I made imagemagick work on azure websites by using site extension.

You can check the repository for more info:

https://github.com/fatihturgut/azure-imagemagick-nodejs



来源:https://stackoverflow.com/questions/26150375/image-manipulation-using-node-js-on-azure-website

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