Replies: 1 comment 1 reply
-
you don't need chrome driver for Ferrrum only chrome. try spawning chrome process manually with given flags, see the output, I believe I've seen permissions issues in the past |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
This is working great in my DEV environment but in my production app hosted on Heroku, I get the error "Ferrum::ProcessTimeoutError (Browser did not produce websocket url within 30 seconds, try to increase
:process_timeout
.I have the required Heroku supported buildpack for Chrome, and am using the headless and no-sandbox options on the Browser.new command,
The heroku Which commands return a path for both
Chrome: /app/.chrome-for-testing/chrome-linux64/chrome
and
Chrome driver: /app/.chrome-for-testing/chromedriver-linux64/chromedriver
Has anyone gotten this to work in Heroku?
UPDATE: 4/25/2025 I have this working in Heroku now!
I had read numerous recommendation to add the no-sandbox option which I did as a parameter to the Ferrum::Browser.new paramter list. What I did not realize, is that it needed to be in another parameter called browser_options. Once I added the , browser_options: {'no-sandbox': true} parameter it now works perfectly!
browser = Ferrum::Browser.new(headless: true,
"no-sandbox": true,
"disable-gpu": true,
"print-to-pdf": true,
browser_name: :chrome,
process_timeout: 30,
timeout: 200,
pending_connection_errors: true**, browser_options: {'no-sandbox': true}**)
Beta Was this translation helpful? Give feedback.
All reactions