DEV Community

Joseph Jessie Oñate
Joseph Jessie Oñate

Posted on

opencv-python on deploying heroku app

In order to deploy and run properly the applications in heroku that uses opencv-python, you need to include the heroku-buildpack-multi by running this command:

heroku config:add BUILDPACK_URL=https://github.com/ddollar/heroku-buildpack-multi.git --app MYAPP

then create a new file Aptfile with the following content:

libsm6
libxrender1
libfontconfig1
libice6

deploy it and your opencv app will work fine now!

Top comments (4)

Collapse
 
rdil profile image
Reece Dunham

Nice post!

One suggestion, you might want to put the code in Markdown code blocks.

Collapse
 
iamjcoo profile image
Joseph Jessie Oñate

oh yeah sure, thanks

Collapse
 
allarounddev profile image
allarounddev

Who can help me for underwater video/image processing using python opencv?

Collapse
 
ihebmankai profile image
Iheb Mankai

How to create an Aptfile and where?