Commit Graph

21 Commits

Author SHA1 Message Date
Max Schmitt
c3566d259f
chore: better error messages when stable channel installations fail on Windows (#29077)
https://github.com/microsoft/playwright/issues/29004
2024-01-22 18:15:35 +01:00
Max Schmitt
38a0921845
fix: Google Chrome Beta/Stable install on macOS (#27880) 2023-10-31 16:49:13 +01:00
Max Schmitt
b387249e45
chore: enhance download/install logic of branded browsers (#26806)
- Remove the check for 32 vs. 64 bit, since we only support 64 Windows
since a while
- Introduce `$ErrorActionPreference = 'Stop'` which is a best practice
otherwise the code would have continued running even a statement/line
was failing. E.g. download failed, it would still try to install
- `$ms.DownloadFile` checks for the status code internally, so we are
safe regarding this, it will throw otherwise.

This won't fix https://github.com/microsoft/playwright/issues/26591 but
makes the code more safe and might be related.
2023-08-31 22:48:07 +02:00
Max Schmitt
5c41c6e799
chore: allow installing Google Chrome on Debian (#24386)
Fixes https://github.com/microsoft/playwright/issues/24357
2023-07-25 00:52:19 +02:00
Patrick Shaw
6e78dcb7dc
fix: Allow portable bash paths for systems including NixOS (#23889)
Although very common, bash is not guaranteed to be located at
`/bin/bash`. NixOS is an example of this.

More commonly, `/bin/bash` can be quite out of date. An example of this
is MacOS's version of `bash`. This realistically won't affect Playwright
but it's worth noting. You can technically update MacOS's system version
of bash but you need elevated permissions to do so.

By using `/usr/bin/env bash` instead of `/bin/bash` we can execute
Playwright's bash scripts in like NixOS and generally improve the
selection behaviour for bash in other systems too.

Some discussion of why it's worth favouring `/usr/bin/env bash` over
`/bin/bash`:
- Discusses `/bin/bash` missing in NixOS:
https://discourse.nixos.org/t/add-bin-bash-to-avoid-unnecessary-pain/5673
- Some general commentary on why `/usr/bin/env bash` is favoured:
https://askubuntu.com/a/1402721
- Points out how old bash is in MacOS:
https://itnext.io/upgrading-bash-on-macos-7138bd1066ba

Improves situation at #5501
2023-07-03 06:27:06 -07:00
Andrey Lushnikov
0a752f3fd6
chore(docker): remove experimental docker integration (#20676)
This removes everything related to docker integration experiments that
we conducted over the last 6 months.

I'll send a follow-up with an alternative suggestion that was demo'ed on
a team meeting in the end of December.
2023-02-06 10:50:45 -08:00
Dmitry Gozman
71798d658f
chore: remove separate network tethering client connection (#20267) 2023-01-21 18:18:22 -08:00
Andrey Lushnikov
858c2453b3
feat(containers): implement reverse proxy for novnc and server (#18569)
This patch adds a reverse proxy in front of novnc and playwright
server inside the container.

As a result:
- container exposes a single HTTP port to the host
- all Playwright clients can connect using this exposed port, e.g.
  `http://127.0.0.1:5400`
- navigating to the exposed port in the browser lands on a nice HTML
page
  with a link to view container screen
- users can also manually navigate to `http://127.0.0.1:5400/screen` to
  view screen
2022-12-08 17:17:18 -08:00
Andrey Lushnikov
8538f61a72
feat(containers): implement global network tethering for playwright server (#17719)
This patch implements a new mode of network tethering for Playwright
server & its clients.
With this patch:
- playwright server could be launched with the
`--browser-proxy-mode=tether` flag to engage in the new mode
- a new type of client, "Network Tethering Client" can connect to the
server to provide network traffic to the browsers
- all clients that connect to the server with the `x-playwright-proxy:
*` header will get traffic from the "Network Tethering Client"

This patch also adds an environment variable
`PW_OWNED_BY_TETHER_CLIENT`. With this env, playwright server will
auto-close when the network tethering client disconnects. It will also
auto-close if the network client does not connect to the server in the
first 10 seconds of the server existence. This way we can ensure that
`npx playwright docker start` blocks terminal & controls the lifetime of
the started container.
2022-11-03 13:47:51 -07:00
Pavel Feldman
4d53fd9c63
chore: download android driver from the cdn (#18466) 2022-10-31 16:08:26 -07:00
Andrey Lushnikov
4cd2176155
feat(containers): introduce separate container commands (#17541)
This patch introduces hidden commands to control container
lifecycle:
- `npx playwright docker install-server-deps` to install fluxbox,
  vnc, novnc & to configure them.
- `npx playwright docker run-server` to run a server inside the
  container.

Drive-by: remove old version of container image when building a new
version with the same name. This way we won't pile up untagged
container images.
2022-09-22 13:38:54 -07:00
Cody Kaup
6a54b5ec88
chore: Fix README link (#17148) 2022-09-07 09:05:43 -07:00
Andrey Lushnikov
1e1a6acaf7
fix: proper chrome-beta channel installation on MacOS (#11973)
chrome-beta installation on MacOS should download universal binaries.

The old download URL for chrome-beta was downloading Chrome Beta M96
2022-02-09 11:28:51 -08:00
Andrey Lushnikov
3c27badd31
fix: bail early when installing channels on non-ubuntu (#11617)
Fixes #11615
2022-01-25 09:13:42 -08:00
Max Schmitt
5610974312
chore: fix installing of branded browsers under non-root (#10640) 2021-12-06 14:49:22 -08:00
Max Schmitt
aba52be169
chore: use curl instead of wget when installing stable channels (#10637) 2021-12-01 18:26:28 +01:00
Andrey Lushnikov
3e96dcd82a
chore: bail out stable installation when running on Linux Arm64 (#9991)
Stable browser channels are only shipped on x86
2021-11-02 16:01:30 -07:00
Max Schmitt
a2c414cd88
chore: add Microsoft Edge Stable on Linux (#9915) 2021-11-01 22:03:51 +01:00
Max Schmitt
dd1d3c3ed9 Revert "chore: migrate away from ps1 in install-deps on Windows (#9876)"
This reverts commit 59a406a586.
2021-10-29 20:12:46 +02:00
Max Schmitt
59a406a586
chore: migrate away from ps1 in install-deps on Windows (#9876) 2021-10-29 19:32:56 +02:00
Joel Einbinder
c89d5a50dd
chore: migrate to monorepo (#9421) 2021-10-11 16:52:17 +02:00