Galera not exposing any ports?

Does anyone know if it is correct that the only ports being exposed by containers for the Galera catalog entry is the 3306:3307 mapping on the load balancer?

I am trying to get a Galera cluster working for a Rancher HA Server setup. I have set up a rancher “parent” server which has 3 hosts onto which I have started a Galera stack.

I am now trying to start up a Rancher bootstrap server container to do the initial database population. I keeping running into issues with connecting to the cluster.

I am trying to start the rancher/server container using :

...
-e CATTLE_DB_CATTLE_MYSQL_HOST=<IP of the docker host with the galrea-lb container> \
-e CATTLE_DB_CATTLE_MYSQL_NAME=rancher \
-e CATTLE_DB_CATTLE_MYSQL_PORT=3306 \
-e CATTLE_DB_CATTLE_PASSWORD=rancherdbpass \
-e CATTLE_DB_CATTLE_USERNAME=rancher \
...

I keep getting “(111 “Connection refused”)”

To me it looks like the lb container is not exposing port 3306. Am I overlooking something or is that correct?

An update…

I tried using a cloned version of the catalog entry with port 3306 being exposed with the “ports” property rather than the “expose” property.

This helped and means that I can now connect to the mariadb on the host with the lb container - using the hosts IP address.

I get a bunch of errors with “…[liquibase] modifyDataType will lose primary key” when starting up and using the database. At this point, the startup of rancher server using this database hangs.

Stopping, removing and the starting my bootstrap rancher server container seems to continue the initialization process.

I also just installed RancherOS on 3 Nodes and tried to get the HA setup running. I have the same issue, the galera-lb is now showing any ports with docker ps. I also cant connect.

Thanks for the hint, to use “port” instead of “expose”. I will give it a try