Using IP of Node was think which I was trying to avoid. I am trying to build HA cluster and when application reaches Node via IP addres there will have to be some HA Proxy in front of MySQL.
When I will use hostpath with socket I can reach a way how to propagate MySQL through socket and on every Node it will be the same so if one node fails application get rescheduled and than it again can reach MySQL through socket. David Strejc t: +420734270131 e: david.str...@gmail.com On Wed, Feb 10, 2016 at 2:51 PM, Ben Parees <bpar...@redhat.com> wrote: > You should be able to access the node's mysql port from within the > container w/o doing anything special, just providing the node host/ip+port > to the container. > > For the mysql socket, you'd have to mount it into the pod/container as a > HostPath volume, I think. > > > On Wed, Feb 10, 2016 at 7:36 AM, David Strejc <david.str...@gmail.com> > wrote: > >> I got different setup. >> >> I have Node with MySQL installed on it (it is MariaDB galera cluster) - >> as my scenario consists of five nodes each running Open Shift, GlusterFS >> and MariaDB directly on Node. >> >> What I want is to expose Node port (3306) or Node MariaDB socket INTO >> docker container. >> >> Is this possible? >> >> David Strejc >> t: +420734270131 >> e: david.str...@gmail.com >> >> On Wed, Feb 10, 2016 at 1:34 PM, Clayton Coleman <ccole...@redhat.com> >> wrote: >> >>> You want the MySQL container to be exposed on the host address? Or you >>> want another non-MySQL container to be able to access the MySQL container? >>> >>> On Feb 10, 2016, at 7:04 AM, David Strejc <david.str...@gmail.com> >>> wrote: >>> >>> Dear all, >>> >>> I have MySQL cluster running on all nodes of Open Shift and I need to >>> expose 3306 port FROM Host into docker container - or propagate >>> /var/run/mysqld/mysqld.socket into docker container. >>> >>> Is this possible with Open Shift? >>> David Strejc >>> t: +420734270131 >>> e: david.str...@gmail.com >>> >>> _______________________________________________ >>> users mailing list >>> users@lists.openshift.redhat.com >>> http://lists.openshift.redhat.com/openshiftmm/listinfo/users >>> >>> >> >> _______________________________________________ >> users mailing list >> users@lists.openshift.redhat.com >> http://lists.openshift.redhat.com/openshiftmm/listinfo/users >> >> > > > -- > Ben Parees | OpenShift > >
_______________________________________________ users mailing list users@lists.openshift.redhat.com http://lists.openshift.redhat.com/openshiftmm/listinfo/users