Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Part of #2504
Builds off #2554
This PR makes it so we can run Playwright in headed mode and use its GUI tools like trace viewer, inspector, debugger, etc.
Credit goes to this blog post for its helpful explanation: https://www.oddbird.net/2022/11/30/headed-playwright-in-docker/
Trying it out
In your .env file, add this environment variable based on your host platform:
DISPLAY=:0
DISPLAY=host.docker.internal:0
DISPLAY=$DISPLAY
For Windows, see this section for some steps you can run to verify this will work: # Microsoft Windows
For macOS, see this section for some additional steps that are needed: # macOS
Then, in a terminal, run:
to start a session inside the
playwright
container.Then in that session, run:
You should see a browser window pop up that goes to the dev-benefits healthcheck.