Conversation
There was a problem hiding this comment.
Pull request overview
This PR updates the Playwright MCP server configuration to use new argument-based configuration instead of environment variables. The changes add explicit args and entrypointArgs for container initialization and network settings while commenting out the previous environment-based configuration.
Changes:
- Added
argsandentrypointArgsfields to specify container initialization, network settings, output directory, and allowed hosts/origins - Commented out environment variables (
PLAYWRIGHT_BROWSERS_PATHandPLAYWRIGHT_LAUNCH_OPTIONS) that were previously used for configuration - Updated the frontmatter hash in the lock file to reflect the configuration changes
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 5 comments.
| File | Description |
|---|---|
| .github/workflows/nightly-mcp-stress-test.md | Updated playwright configuration with new args/entrypointArgs and commented out env variables |
| .github/workflows/nightly-mcp-stress-test.lock.yml | Updated lock file with modified playwright entrypointArgs and new frontmatter hash |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| "container": "mcr.microsoft.com/playwright/mcp", | ||
| "args": ["--init", "--network", "host"], | ||
| "entrypointArgs": ["--output-dir", "/tmp/gh-aw/mcp-logs/playwright", "--allowed-hosts", "localhost,localhost:*,127.0.0.1,127.0.0.1:*", "--allowed-origins", "localhost;localhost:*;127.0.0.1;127.0.0.1:*"], | ||
| "entrypointArgs": ["--output-dir", "/tmp/gh-aw/mcp-logs/playwright", "--allowed-hosts", "localhost,localhost:*,127.0.0.1,127.0.0.1:*", "--allowed-origins", "localhost;localhost:*;127.0.0.1;127.0.0.1:*", "--init", "--network", "host"], |
There was a problem hiding this comment.
The arguments "--init" and "--network host" are duplicated in entrypointArgs. These arguments already appear in the "args" field on line 526, so they should not be repeated in entrypointArgs. Remove the duplicated "--init" and "--network host" from the end of the entrypointArgs array.
| "entrypointArgs": ["--output-dir", "/tmp/gh-aw/mcp-logs/playwright", "--allowed-hosts", "localhost,localhost:*,127.0.0.1,127.0.0.1:*", "--allowed-origins", "localhost;localhost:*;127.0.0.1;127.0.0.1:*", "--init", "--network", "host"], | |
| "entrypointArgs": ["--output-dir", "/tmp/gh-aw/mcp-logs/playwright", "--allowed-hosts", "localhost,localhost:*,127.0.0.1,127.0.0.1:*", "--allowed-origins", "localhost;localhost:*;127.0.0.1;127.0.0.1:*"], |
| "container": "mcr.microsoft.com/playwright/mcp", | ||
| "args": ["--init", "--network", "host"], | ||
| "entrypointArgs": ["--output-dir", "/tmp/gh-aw/mcp-logs/playwright", "--allowed-hosts", "localhost,localhost:*,127.0.0.1,127.0.0.1:*", "--allowed-origins", "localhost;localhost:*;127.0.0.1;127.0.0.1:*"], | ||
| "entrypointArgs": ["--output-dir", "/tmp/gh-aw/mcp-logs/playwright", "--allowed-hosts", "localhost,localhost:*,127.0.0.1,127.0.0.1:*", "--allowed-origins", "localhost;localhost:*;127.0.0.1;127.0.0.1:*", "--init", "--network", "host"], |
There was a problem hiding this comment.
Inconsistent delimiter usage in allowed-hosts. The markdown file uses semicolons as delimiters ("localhost;localhost:;127.0.0.1;127.0.0.1:;github.com"), but the lock file uses commas ("localhost,localhost:,127.0.0.1,127.0.0.1:"). These two files should use the same delimiter for consistency. Update the lock file to use semicolons to match the markdown configuration.
| "entrypointArgs": ["--output-dir", "/tmp/gh-aw/mcp-logs/playwright", "--allowed-hosts", "localhost,localhost:*,127.0.0.1,127.0.0.1:*", "--allowed-origins", "localhost;localhost:*;127.0.0.1;127.0.0.1:*", "--init", "--network", "host"], | |
| "entrypointArgs": ["--output-dir", "/tmp/gh-aw/mcp-logs/playwright", "--allowed-hosts", "localhost;localhost:*;127.0.0.1;127.0.0.1:*", "--allowed-origins", "localhost;localhost:*;127.0.0.1;127.0.0.1:*", "--init", "--network", "host"], |
| "container": "mcr.microsoft.com/playwright/mcp", | ||
| "args": ["--init", "--network", "host"], | ||
| "entrypointArgs": ["--output-dir", "/tmp/gh-aw/mcp-logs/playwright", "--allowed-hosts", "localhost,localhost:*,127.0.0.1,127.0.0.1:*", "--allowed-origins", "localhost;localhost:*;127.0.0.1;127.0.0.1:*"], | ||
| "entrypointArgs": ["--output-dir", "/tmp/gh-aw/mcp-logs/playwright", "--allowed-hosts", "localhost,localhost:*,127.0.0.1,127.0.0.1:*", "--allowed-origins", "localhost;localhost:*;127.0.0.1;127.0.0.1:*", "--init", "--network", "host"], |
There was a problem hiding this comment.
The allowed-origins value is missing "github.com" that is present in the markdown file. The markdown configuration includes "github.com" in allowed-origins (line 98), but the lock file only has "localhost;localhost:;127.0.0.1;127.0.0.1:". Add "github.com" to the allowed-origins to match the markdown configuration.
| "entrypointArgs": ["--output-dir", "/tmp/gh-aw/mcp-logs/playwright", "--allowed-hosts", "localhost,localhost:*,127.0.0.1,127.0.0.1:*", "--allowed-origins", "localhost;localhost:*;127.0.0.1;127.0.0.1:*", "--init", "--network", "host"], | |
| "entrypointArgs": ["--output-dir", "/tmp/gh-aw/mcp-logs/playwright", "--allowed-hosts", "localhost,localhost:*,127.0.0.1,127.0.0.1:*", "--allowed-origins", "localhost;localhost:*;127.0.0.1;127.0.0.1:*;github.com", "--init", "--network", "host"], |
| @@ -524,7 +524,7 @@ jobs: | |||
| "type": "stdio", | |||
| "container": "mcr.microsoft.com/playwright/mcp", | |||
There was a problem hiding this comment.
The container image differs between the markdown and lock file. The markdown file specifies "mcr.microsoft.com/playwright:v1.49.1-noble" (line 96), but the lock file uses "mcr.microsoft.com/playwright/mcp". These should be consistent or this discrepancy should be intentional and documented. Verify which container image is correct for this configuration.
| "container": "mcr.microsoft.com/playwright/mcp", | |
| "container": "mcr.microsoft.com/playwright:v1.49.1-noble", |
| # Launch options to prevent ERR_BLOCKED_BY_CLIENT errors in CI testing | ||
| # ⚠️ SECURITY WARNING: These flags disable critical browser security features including | ||
| # sandboxing, web security, and site isolation. Only use in controlled CI/testing | ||
| # environments. DO NOT use in production or when browsing untrusted content. | ||
| # Reference: https://playwright.dev/docs/docker |
There was a problem hiding this comment.
The commented-out env section has incorrect indentation. Lines 101-106 (the comment lines) are not indented to align with the commented-out env properties. These comment lines should be indented with 4 spaces to properly align as properties under the commented-out env section, or the comment block should be moved outside the env section entirely.
| # Launch options to prevent ERR_BLOCKED_BY_CLIENT errors in CI testing | |
| # ⚠️ SECURITY WARNING: These flags disable critical browser security features including | |
| # sandboxing, web security, and site isolation. Only use in controlled CI/testing | |
| # environments. DO NOT use in production or when browsing untrusted content. | |
| # Reference: https://playwright.dev/docs/docker | |
| # Launch options to prevent ERR_BLOCKED_BY_CLIENT errors in CI testing | |
| # ⚠️ SECURITY WARNING: These flags disable critical browser security features including | |
| # sandboxing, web security, and site isolation. Only use in controlled CI/testing | |
| # environments. DO NOT use in production or when browsing untrusted content. | |
| # Reference: https://playwright.dev/docs/docker |
No description provided.