Proxy Configuration
Configure a default HTTP proxy for all browser sessions launched by Donobu.
Donobu can route browser traffic through an HTTP proxy by setting the following environment variables before running your tests. These apply to all browser sessions that do not have an explicit proxy configured in playwright.config.ts.
Environment variables
| Variable | Description |
|---|---|
PROXY_SERVER | Default proxy URL for browser sessions (e.g. http://proxy.internal:3128) |
PROXY_USERNAME | Username for proxy authentication |
PROXY_PASSWORD | Password for proxy authentication |
Example
export PROXY_SERVER=http://proxy.example.com:3128
export PROXY_USERNAME=myuser
export PROXY_PASSWORD=mypassword
npx donobu test
Per-project proxy configuration
To configure a proxy for a specific Playwright project rather than globally, use the proxy option in playwright.config.ts:
export default defineConfig({
projects: [
{
name: 'proxied',
use: {
proxy: {
server: 'http://proxy.example.com:3128',
username: 'myuser',
password: 'mypassword',
},
},
},
],
});
See Playwright's proxy documentation for the full set of proxy options.