docker-compose.yml 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. version: '3.4'
  2. services:
  3. selenium-hub:
  4. image: selenium/hub:4.41.0
  5. container_name: selenium-hub
  6. ports:
  7. - "4444:4444" # WebDriver API
  8. - "4442:4442" # event bus publish
  9. - "4443:4443" # event bus subscribe
  10. environment:
  11. - SE_OPTS=--log-level INFO
  12. - TZ=Europe/Tallinn
  13. - LANG=C.UTF-8
  14. volumes:
  15. - /etc/localtime:/etc/localtime
  16. restart: unless-stopped
  17. networks:
  18. - ai_network
  19. selenium-chrome:
  20. image: selenium/node-chrome:4.41.0
  21. container_name: selenium-chrome
  22. depends_on:
  23. - selenium-hub
  24. environment:
  25. - SE_EVENT_BUS_HOST=selenium-hub
  26. - SE_EVENT_BUS_PUBLISH_PORT=4442
  27. - SE_EVENT_BUS_SUBSCRIBE_PORT=4443
  28. - SE_NODE_MAX_SESSIONS=4
  29. - SE_NODE_OVERRIDE_MAX_SESSIONS=true
  30. - SE_VNC_NO_PASSWORD=1 # Disable VNC password
  31. - TZ=Europe/Tallinn
  32. - LANG=C.UTF-8
  33. volumes:
  34. - /etc/localtime:/etc/localtime
  35. shm_size: 2gb
  36. restart: unless-stopped
  37. ports:
  38. - "7900:7900"
  39. networks:
  40. - ai_network
  41. selenium-firefox:
  42. image: selenium/node-firefox:4.41.0
  43. container_name: selenium-firefox
  44. depends_on:
  45. - selenium-hub
  46. environment:
  47. - SE_EVENT_BUS_HOST=selenium-hub
  48. - SE_EVENT_BUS_PUBLISH_PORT=4442
  49. - SE_EVENT_BUS_SUBSCRIBE_PORT=4443
  50. - SE_NODE_MAX_SESSIONS=4
  51. - SE_NODE_OVERRIDE_MAX_SESSIONS=true
  52. - SE_VNC_NO_PASSWORD=1 # Disable VNC password
  53. - TZ=Europe/Tallinn
  54. - LANG=C.UTF-8
  55. volumes:
  56. - /etc/localtime:/etc/localtime
  57. # sudo cp -r ~/.mozilla/firefox/xxxx.default /tmp/firefox-profile
  58. - /tmp/firefox-profile:/home/seluser/firefox-profile:ro
  59. shm_size: 2gb
  60. restart: unless-stopped
  61. ports:
  62. - "7901:7900"
  63. networks:
  64. - ai_network
  65. browserless:
  66. image: browserless/chrome
  67. restart: unless-stopped
  68. ports:
  69. - "3001:3000"
  70. environment:
  71. - MAX_CONCURRENT_SESSIONS=5
  72. - CONNECTION_TIMEOUT=60000
  73. - TZ=Europe/Tallinn
  74. volumes:
  75. - /etc/localtime:/etc/localtime
  76. networks:
  77. - ai_network
  78. networks:
  79. ai_network:
  80. external: true
  81. name: main_ai_network