Port 4444 accessible, but ports 4442 & 4443 can't be reached (Stuck for hours of not understanding documentation)

If someone could quickly guide me.
On how I would deploy the selenium grid stack (I am creating an automation service for my SaaS).

And am getting stuck when deploying to fly (works perfectly locally).
Ports 4443 & 4442 aren’t working (And I would prefer to use port 4444, but that also doesn’t work if I remove the http_service from the fly.toml file:

# fly.toml app configuration file generated for tesst on 2024-08-11T13:28:12+02:00
#
# See https://fly.io/docs/reference/configuration/ for information about how to use this file.
#

app = 'tesst'
primary_region = 'jnb'

[build]
  dockerfile = "Dockerfile"

[http_service]
  internal_port = 4444 
  force_https = false 
  min_machines_running = 0
  processes = ['app']
  auto_stop_machines = true 
  auto_start_machines = true

[[services]]
  internal_port = 4444
  protocol = "tcp"

  [[services.ports]]
    port = 4444

[[services]]
  internal_port = 4442
  protocol = "tcp"
  external_port = 4442

  [[services.ports]]
    port = 4442

[[services]]
  internal_port = 4443
  external_port = 4443 
  protocol = "tcp"

  [[services.ports]]
    port = 4443

Dockerfile:

FROM selenium/standalone-chrome

ENTRYPOINT ["java", "-Dwebdriver.chrome.driver=/usr/bin/chromedriver", "-Dwebdriver.edge.driver=/usr/bin/msedgedriver", "-Dwebdriver.gecko.driver=/usr/bin/geckodriver", "-jar", "/opt/selenium/selenium-server.jar", "hub", "--bind-host", "true", "--host", "0.0.0.0"]


And when trying to connect a node to the fly machine:
java -jar Selenium\ Server\ 4.23.0.jar node --hub 213.188.209.165
18:29:48.052 INFO [LoggingOptions.configureLogEncoding] - Using the system default encoding
18:29:48.054 INFO [OpenTelemetryTracer.createTracer] - Using OpenTelemetry for tracing
18:29:48.094 INFO [UnboundZmqEventBus.] - Connecting to tcp://213.188.209.165:4442 and tcp://213.188.209.165:4443
18:29:48.109 INFO [UnboundZmqEventBus.] - Sockets created
18:29:49.115 INFO [UnboundZmqEventBus.] - Event bus ready
18:29:49.201 INFO [NodeServer.createHandlers] - Reporting self as: http://192.168.3.168:5555
18:29:49.209 INFO [NodeOptions.getSessionFactories] - Detected 8 available processors
18:29:49.209 INFO [NodeOptions.discoverDrivers] - Looking for existing drivers on the PATH.
18:29:49.209 INFO [NodeOptions.discoverDrivers] - Add ‘–selenium-manager true’ to the startup command to setup drivers automatically.
18:29:49.451 WARN [SeleniumManager.lambda$runCommand$1] - Unable to discover proper msedgedriver version in offline mode
18:29:49.586 WARN [SeleniumManager.lambda$runCommand$1] - Unable to discover proper geckodriver version in offline mode
18:29:49.605 WARN [SeleniumManager.lambda$runCommand$1] - Unable to download safaridriver in offline mode
18:29:49.616 INFO [NodeOptions.report] - Adding Firefox for {“browserName”: “firefox”,“platformName”: “mac”} 8 times
18:29:49.616 INFO [NodeOptions.report] - Adding Safari for {“browserName”: “safari”,“platformName”: “mac”} 1 times
18:29:49.617 INFO [NodeOptions.report] - Adding Chrome for {“browserName”: “chrome”,“platformName”: “mac”} 8 times
18:29:49.617 INFO [NodeOptions.report] - Adding Edge for {“browserName”: “MicrosoftEdge”,“platformName”: “mac”} 8 times
18:29:49.617 INFO [NodeOptions.report] - Adding Safari Technology Preview for {“browserName”: “Safari Technology Preview”,“platformName”: “mac”} 1 times
18:29:49.641 INFO [Node.] - Binding additional locator mechanisms: relative
18:29:49.703 INFO [NodeServer$1.start] - Starting registration process for Node http://192.168.3.168:5555
18:29:49.703 INFO [NodeServer.execute] - Started Selenium node 4.23.0 (revision 4df0a231af): http://192.168.3.168:5555
18:29:49.712 INFO [NodeServer$1.lambda$start$1] - Sending registration event…
18:29:59.721 INFO [NodeServer$1.lambda$start$1] - Sending registration event…
18:30:09.735 INFO [NodeServer$1.lambda$start$1] - Sending registration event…
18:30:19.750 INFO [NodeServer$1.lambda$start$1] - Sending registration event…
18:30:29.765 INFO [NodeServer$1.lambda$start$1] - Sending registration event…
18:30:39.782 INFO [NodeServer$1.lambda$start$1] - Sending registration event…
18:30:49.798 INFO [NodeServer$1.lambda$start$1] - Sending registration event…
18:30:59.808 INFO [NodeServer$1.lambda$start$1] - Sending registration event…
18:31:09.818 INFO [NodeServer$1.lambda$start$1] - Sending registration event…
18:31:19.827 INFO [NodeServer$1.lambda$start$1] - Sending registration event…
18:31:29.839 INFO [NodeServer$1.lambda$start$1] - Sending registration event…
18:31:39.861 INFO [NodeServer$1.lambda$start$1] - Sending registration event…
18:31:49.708 INFO [NodeServer$1.lambda$start$1] - Sending registration event…

(It is a dedicated ipv4, I also tried just using the hostname, but that also doesn’t work!)

From General to Questions / Help

Added machines

Where are you seeing this? I don’t think external_port exists unless it’s legacy config.
You also have a redundant http_service and services for port 4444, that may cause issues.

Thanks. Will try removing the external_port & also remove the http_service.
Hope tha thelps!

Thanks for the help!
Will comment if I get / don’t get it working!

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.