-
Notifications
You must be signed in to change notification settings - Fork 0
feat(auth): add webServer.env #11
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR adds support for environment variable overrides in the webServer configuration, following Playwright's design pattern. Users can now specify custom environment variables for their web server process through the webServer.env configuration option.
Key Changes:
- Added
env?: Record<string, string>field to webServer configuration with validation - Updated web server spawning logic to merge custom env with process.env
- Added comprehensive test coverage and documentation
Reviewed changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| packages/auth/src/config/types.ts | Added optional env field to AuthWebServerConfig interface with documentation |
| packages/auth/src/config/loadAuthConfig.ts | Added validation to ensure webServer.env values are strings |
| packages/auth/src/cli/webServer.ts | Updated spawn logic to merge webServer.env with process.env |
| packages/auth/src/cli/args.ts | Added env field to WebServerArgs interface for consistency |
| packages/auth/src/cli/main.ts | Refactored webServer resolution logic to properly pass through env from config |
| packages/auth/src/tests/configFindAndLoad.test.ts | Added test cases for valid env usage and rejection of non-string values |
| packages/auth/README.md | Added documentation example showing env usage |
| README.md | Added documentation example showing env usage |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 15 out of 15 changed files in this pull request and generated no new comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Adds Playwright-style env overrides for the auth CLI webServer process.