Deploying python bokeh to heroku


I’m having trouble uploading my bokeh app to heroku. I get this error: “error: unrecognized arguments: --port:14660.”

On my procfile, I have: “web: bokeh serve --port:$PORT --address= --num-procs=0 --allow-websocket-origin=* --use-xheaders”

Can someone please tell me what I’m doing wrong.

Thank you :pray:

Is it possible it’s a syntax error? According to the docs, it looks like that ‘:’ after --port is unnecessary. Have you tried without?

1 Like

As @carolyn mentioned, you wouldn’t need : after --port. Below code works fine for me. Replace app_name with your heroku app name.

web: bokeh serve --port=$PORT --allow-websocket-origin=app_name --address= --use-xheaders myapp

I’m not sure if can be mentioned instead of myapp (bokeh server folder name).

1 Like

Thank you. It worked with --port=$PORT instead of --port:$PORT.

1 Like