Saturday, June 10, 2017

CBF2 now supporting multiple instances running

CBF2 now supporting multiple instances running




The scenario


Last year I announced CBF2, the biggest, best, coolest way to manage Pentaho projects, available on github. In case you dont recall, it relies on docker to manage the images. Just read about it - really awesome

Since then, weve been using it a lot here. Really helps managing different projects and environments, and its been put up to test in multiple real world scenarios.

One of the limitations of CBF2 is that its limited to running one project per machine - since it exposes the ports on the host machine. 

Another immediate consequence is that we cant have a local tomcat running since wed get port conflicts.

The need

However, sometimes its useful to have running containers side by side. In this case, we wouldnt be able to run these two projects at the same time:

So I guess I have to run these two projects one at a time?

If you tried to run these two it would complain about conflicting ports and the likes of it.

The solution


Turns out Kleyson Rios was less clumsy than I am - so he implemented this feature in CBF2: The ability to have containers running side by side by automagically detecting used ports and just moving on to the next one.

In here you see that both containers successfully ran:

2 projects running side by side

The result


The end result? Pretty cool, I have to admit! I now can run and test different versions side by side on my machine just by using the correct port :)

2 different versions, 5.4 and 7.1, running on my machine with 2 simple commands


This improvement is already committed, so simply pull the latest version and youre ready to go.


Thanks Kleyson! :)


-pedro