- Playwright config for local browsers (Firefox by default) and Docker Chrome - docker-compose.chrome.yml for browserless/chrome container (arm64) - 4 connectivity smoke tests (home, contact, blog pages) - 3 auth tests (redirect, login, logout) with auth helpers - Custom fixtures with remote CDP connect support - Shell scripts for start/stop/full Docker Chrome workflow - Makefile targets: playwright, playwright-docker, playwright-full
27 lines
978 B
YAML
27 lines
978 B
YAML
# Docker Compose for Playwright Chrome container
|
|
#
|
|
# Usage:
|
|
# docker compose -f docker-compose.chrome.yml up -d # start Chrome
|
|
# docker compose -f docker-compose.chrome.yml down # stop Chrome
|
|
# make playwright # run tests against it
|
|
#
|
|
# The container exposes Chrome DevTools Protocol on port 9222.
|
|
# Playwright connects via the websocket endpoint.
|
|
|
|
services:
|
|
chrome:
|
|
# browserless/chrome is self-contained with Chrome + CDP exposed
|
|
# multi-arch (supports arm64 for Apple Silicon Macs)
|
|
image: browserless/chrome:latest
|
|
container_name: firehose-playwright-chrome
|
|
ports:
|
|
- "3000:3000" # browserless dashboard (not required but handy)
|
|
environment:
|
|
- CONNECTION_TIMEOUT=600000
|
|
- MAX_CONCURRENT_SESSIONS=10
|
|
- PREBOOT_CHROME=true
|
|
- DEMO_MODE=false
|
|
- ENABLE_CORS=true
|
|
restart: unless-stopped
|
|
# Run as non-root to avoid permission issues
|
|
user: "1001:1001" |