I want to run xvfb on Heroku. On my mac, I used dmg to install it. Can anyone think how to do this on Geroku?
I came across these buildpacks ( http://github.com/douglasjsellers/heroku-xvfb-buildpack ), but following the instructions, it seems that the problem could not be solved, since xvfb is still not installed correctly. Also, I tried installing xvfbwrapper ( https://pypi.python.org/pypi/xvfbwrapper/0.1.0 ), but it still does not work on Heroku (apologies for being potentially a noob issue).
Here is the error I get in my journals from Heroku:
2015-02-24T02:09:16.035298+00:00 app[web.6]: cmd=['Xvfb', '-help']
2015-02-24T02:09:16.035564+00:00 app[web.6]: Program install error!
2015-02-24T02:09:16.035302+00:00 app[web.6]: OSError=[Errno 2] No such file or directory
Here is the code:
temp = tempfile.mkstemp(suffix='.html')
html = os.fdopen(temp[0], "r+")
html.write(cv)
html.seek(0, 0)
display = Display(visible=0, size=(800, 600))
display.start()
driver = webdriver.Firefox()
driver.get("file://" + temp[1])
source
share