Circleci/node:4.8-browsers image fails to start Chrome

chrome
2.0

#1

I recently started an attempt to upgrade some existing testing setups to Circle 2.0, and am running into a problem getting Chrome to start. The project is an Ember project, and the tests are run in Chrome with the help of testem, using the circleci/node:4.8-browsers base image.

When attempting to start Chrome, the following error occurs:

Error: Browser exited unexpectedly Non-zero exit code: 1 Stderr:   [0727/183643.547535:ERROR:nacl_helper_linux.cc(311)] NaCl helper process running without a sandbox! 
Most likely you need to configure your SUID sandbox correctly

Some Googling seemed to indicated that providing some combination of --no-sandbox, --disable-setuid-sandbox, and --user-data-dir would circumvent this issue, but I have had no success with any combination of the above.

To rule out other issues with the environment, I removed all other steps except an experimental “Start Chrome” step, which also fails. However, this step does not seem to output the reason why. When using ssh to debug, the same error is shown.

I even went so far as to pull down the circleci/node:4.8-browsers image locally, to attempt to reproduce the error there, but ran into some issues with X server, so was unable to reproduce it locally.

I also dug up a previous attempt at the circle upgrade by one of my coworkers, and re-ran that against the current circle configuration. The previous builds were passing, but a large number of tests had been skipped (my reason for starting from a blank state). However, after a rebuild (without cache, to address a build tooling issue), the previously-passing branch is now failing with the same problem my branch is having.

Any thoughts on what the issue might be? I believe the version of Chrome in this image is a newer version than when the previous attempt to do this migration, so it could be related to the version of Chrome installed.

[Edit] I tried a couple other images from the circleci/node tags list, and discovered that circleci/node:6.11.0-browsers and circleci/node:4.8.4-browsers seem to work, but circleci/node:4.8.3-browsers and circleci/node:4.8-browsers do not. My hunch was that something is misconfigured from the builds that are tagged as having been updated “14 days ago”. However, this little experiment seems to have ruled out the timing aspect.


#2

Hey, fwiw we had the same issue using the circleci/node:6-browsers image, and adding the --no-sandbox flag seems to have solved it. Weirdly, the launch failures were intermittent, it’d often work if the entire workflow was restarted but not when restarted the individual jobs.


#3

Yeah, I had no luck with either the --no-sandbox or --disable-setuid-sandbox (nor both).

I also ran into the same issue when ssh’ing into one of the running containers (with VNC) to try to debug some failures by hand. So, while Chrome was apparently starting properly under Circle’s test environment, ssh’ing into the node and attempting to start Chrome on a different display would once again be failing due to the setuid sandbox.


#4

This topic was automatically closed 41 days after the last reply. New replies are no longer allowed.