1
0
mirror of https://github.com/vimagick/dockerfiles.git synced 2024-12-23 01:39:27 +02:00
dockerfiles/selenium/docker-compose.yml
2024-07-19 16:56:41 +08:00

57 lines
1.3 KiB
YAML

#
# https://github.com/SeleniumHQ/docker-selenium/blob/trunk/docker-compose-v3.yml
# https://github.com/SeleniumHQ/docker-selenium/blob/trunk/README.md#configuring-the-containers
#
version: "3.8"
services:
hub:
image: selenium/hub:4
ports:
- "4442:4442"
- "4443:4443"
- "4444:4444"
environment:
- SE_JAVA_OPTS=-Xms256m -Xmx2048m
restart: unless-stopped
chrome:
image: selenium/node-chrome:4
ports:
- "5900:5900"
- "7900:7900"
environment:
- SE_EVENT_BUS_HOST=hub
- SE_EVENT_BUS_PUBLISH_PORT=4442
- SE_EVENT_BUS_SUBSCRIBE_PORT=4443
- SE_NODE_OVERRIDE_MAX_SESSIONS=true
- SE_NODE_MAX_SESSIONS=4
- SE_NODE_SESSION_TIMEOUT=180
- SE_ENABLE_BROWSER_LEFTOVERS_CLEANUP=true
- SE_OPTS=--log-level FINE
- SE_JAVA_OPTS=-Xms256m -Xmx2048m
- START_XVFB=true
- VNC_NO_PASSWORD=1
- VNC_VIEW_ONLY=1
shm_size: 2gb
depends_on:
- hub
restart: unless-stopped
video:
image: selenium/video:ffmpeg-6.1.1-20240621
volumes:
- ./data:/videos
ports:
- "9000:9000"
environment:
- DISPLAY_CONTAINER_NAME=chrome
- SE_VIDEO_FOLDER=/videos
- FILE_NAME=video.mp4
- VIDEO_READY_PORT=9000
depends_on:
- chrome
restart: unless-stopped