Octopus
Enabling the Plugin
The WebDriverPlugin requires Playwright binaries installed on the host. Configuration specifies the browser engine, headless mode, and network allowlist.
Installing Playwright Browsers
# Install Playwright CLI
dotnet tool install --global Microsoft.Playwright.CLI
# Install Chromium (recommended for production)
playwright install chromium
# Install Firefox (optional, for compatibility testing)
playwright install firefox
# On Linux/Docker, also install system dependencies
playwright install-deps chromium
appsettings.json Configuration
{
"WebDriverPlugin": {
"Browser": "Chromium",
"Headless": true,
"SlowMotionMs": 0,
"TimeoutMs": 30000,
"NavigationTimeoutMs": 30000,
"AllowedDomains": [
"*.company.com",
"finance.yahoo.com",
"api.openai.com"
],
"Session": {
"ReuseWithinConversation": true,
"MaxIdleSeconds": 120,
"MaxSessionDurationSeconds": 600
},
"Proxy": {
"Enabled": false,
"Server": "http://proxy.internal:8080",
"Username": "",
"Password": ""
}
}
}
Configuration Properties
| Property | Default | Description |
|---|---|---|
Browser | Chromium | Browser engine: Chromium or Firefox |
Headless | true | Run without visible window. Must be true in production. |
SlowMotionMs | 0 | Delay between actions (ms) — useful for debugging only |
TimeoutMs | 30000 | Default timeout for all browser actions (ms) |
NavigationTimeoutMs | 30000 | Timeout for page navigation actions (ms) |
AllowedDomains | [] | Wildcard domain allowlist. Navigation to unlisted domains is blocked. |
Session.ReuseWithinConversation | true | Whether the same browser context persists across tool calls in one turn |
Session.MaxIdleSeconds | 120 | Idle sessions are closed after this duration |
Docker Deployment
# Dockerfile — add Playwright browser dependencies
FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS runtime
# Install Playwright system dependencies
RUN apt-get update && apt-get install -y \
libnss3 libnspr4 libdbus-1-3 libatk1.0-0 \
libatk-bridge2.0-0 libcups2 libxkbcommon0 \
libxcomposite1 libxdamage1 libxfixes3 libxrandr2 \
libgbm1 libasound2 libpangocairo-1.0-0 \
&& rm -rf /var/lib/apt/lists/*
COPY --from=build /app .
# Install Playwright browser (Chromium) during container build
RUN dotnet tool install --global Microsoft.Playwright.CLI
ENV PATH="${PATH}:/root/.dotnet/tools"
RUN playwright install chromium
RUN playwright install-deps chromium
ENTRYPOINT ["dotnet", "YourOctopusApp.dll"]
Headless mode in production. Always set
Headless: true in production. Non-headless mode requires a display server (X11/Wayland) and will fail to start in most server environments.