Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Launch several browsers in parallel #3

Closed
2 tasks
daviddias opened this issue Oct 31, 2014 · 1 comment
Closed
2 tasks

Launch several browsers in parallel #3

daviddias opened this issue Oct 31, 2014 · 1 comment

Comments

@daviddias
Copy link
Owner

One of the goals for piri-piri is to offer its user an abstraction to launch several browser (or tabs) without much effort, creating this way several nodes present in the app. However, achieving this has been an adventure of its own and still going, trying to find the most scalable way[1] and the easiest. Here are the attempts so far and the current state of them.

browser-launcher2 & launchpad

browser-launcher2 & launchpad are two npm modules that enables a developer to levarage the browsers installed in their machine and start new instances of them, launchpad even has a interface to connect to browserstack and use their own browser instances for the testing. However, the problem resides when trying to open more than one browser, it only allows to pop up one browser per profile.

xvfb-run on mac

haven't gone this path yet

xvfb-run on docker

This was the path that seemed the most interesting one from the start, spawning containers is fast and there is a lot of services out there to deploy them for almost zero cost, however, some hickups met along the way, you can find all the dockerfile+code used for the experiment here: https://github.com/diasdavid/piri-piri/tree/master/dockerExperiment , but in the end when xvfb tries to initialize GFX, it throws this error:

Initializing built-in extension GLX
Xlib:  extension "RANDR" missing on display ":99".
Xlib:  extension "RANDR" missing on display ":99".
[6134:6134:1030/125416:ERROR:desktop_window_tree_host_x11.cc(802)] Not implemented reached in virtual void views::DesktopWindowTreeHostX11::InitModalType(ui::ModalType)
ATTENTION: default value of option force_s3tc_enable overridden by environment.
failed to create drawable
[6175:6175:1030/125416:ERROR:gl_surface_glx.cc(633)] glXCreatePbuffer failed.
[6175:6175:1030/125416:ERROR:gpu_info_collector.cc(27)] gfx::GLContext::CreateOffscreenGLSurface failed
[6175:6175:1030/125416:ERROR:gpu_info_collector.cc(89)] Could not create surface for info collection.
[6175:6175:1030/125416:ERROR:gpu_main.cc(402)] gpu::CollectGraphicsInfo failed (fatal).
[6175:6175:1030/125416:ERROR:sandbox_linux.cc(305)] InitializeSandbox() called with multiple threads in process gpu-process
[6175:6175:1030/125416:ERROR:gpu_child_thread.cc(143)] Exiting GPU process due to errors during initialization
[6134:6134:1030/125416:ERROR:gpu_process_transport_factory.cc(418)] Failed to establish GPU channel.

I honestly don't know how to fix it.

xvfb-run on Vagrant?

This is the current experiment
TODO:

  • Create a Vagrant VM with Node and Google Chrome installed
  • Launch a service with launchpad server

pop up tabs locally

this is the hacky solution I managed to get done so I could advance with the project, however, it is not the goal to continue like this.
update: now launchpad enables to pop up tabs with same profile, so no more child spawn

[1]: One that enables the user to launch browsers in remote instances too

@daviddias
Copy link
Owner Author

note to self: revisit this issue and pursue the idea of spawning browser nodes inside Travis CI
webrtcftw/goals#8 (comment)

update: actually figured out how to actually run browsers inside Docker containers :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant