CLI tries to launch a Chrome instance even when given a remote hostname
See original GitHub issueProvide the steps to reproduce
- Run LH on any URL via the CLI, passing
--hostname
and--port
to point at a remote Chrome instance
What is the current behavior?
Lighthouse launches a local Chrome instance, but ignores it and connects to the remote instance anyways. If this isn’t possible because Chrome isn’t installed (for example, in CI environments), the entire Lighthouse run crashes out.
What is the expected behavior?
Lighthouse doesn’t launch a local Chrome instance (and fail the run if it isn’t installed); it just connects to the remote instance.
Environment Information
- Affected Channels: CLI
- Lighthouse version: 7.2.0
- Chrome version: N/A
- Node.js version: 14.15.4
- Operating System: macOS Catalina 10.15.7
Related issues
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:9 (3 by maintainers)
Top Results From Across the Web
Set up Chrome Remote Desktop for Linux on Compute Engine
This tutorial shows you how to set up the Chrome Remote Desktop service on a Debian Linux virtual machine (VM) instance on Compute...
Read more >How to Connect to a Remote Server Over SSH on Chrome
Open Chrome and type the following into the URL/address bar, replacing [username] with the username of the remote user and [ip-address] with ...
Read more >Command Line Interface | API | Docs - TestCafe
The following example demonstrates how to run a test in two browsers: one browser is specified with an alias, the other browser is...
Read more >Chrome remote debugging doesn't work with IP - Stack Overflow
is the port open on windows? when not you have to add to the a windows firewall rules for this port! – Azd325....
Read more >Configuring a SOCKS proxy server in Chrome
To configure chrome to proxy traffic through the SOCKS v5 proxy server myproxy:8080, launch chrome with these two command-line flags:.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Thanks for taking this, Tyler! let us know if you have any questions.
Thanks for filing @tkindy!
No this issue is really somewhat unrelated to chrome-launcher, if a hostname other than localhost is used, then lighthouse shouldn’t even be trying to launch Chrome.
AFAICT, lighthouse should still respect the hostname setting but you’ll have a useless Chrome launched and sitting around on your localhost as well (and this might fail if Chrome can’t be started on your machine).
https://github.com/GoogleChrome/lighthouse/blob/fb18dfe70e89d752a46deabe2de8a21b414ceb7e/lighthouse-core/index.js#L38-L45
Either way we’ll want to fix that up on the lighthouse side.