Skip to content Skip to sidebar Skip to footer

Deploying Node.js App That Uses Python-shell To Heroku

I have a node.js application that deploys to heroku and runs well (has a simple Procfile that says web: npm start. I have both the node.js and Python buildpacks set. I have the PY

Solution 1:

You need to tell heroku that you need to use python in your project.

  1. First, add the buildpacks for node js & python.
    heroku buildpacks:add --index 1 heroku/nodejs
    heroku buildpacks:add --index 2 heroku/python
    
  2. Next, edit your Procfile to
    pipinstall: pip install -r requirements.txt
    web: npm start
    
  3. Now push to heroku.

Post a Comment for "Deploying Node.js App That Uses Python-shell To Heroku"