Two Instances of Canton on One Physical System

Hi Canton Team,

I have Canton Community version 0.27.0 installed and configured, but also noted that I accidentally selected the Docker install for this Ubuntu Server version when installing the OS.

Is it possible therefore, to run two discrete instances of Canton, one being Canton Native on Ubuntu, with the second being Canton on Docker on Ubuntu?

I have zero experience with Docker but from reading the Documentation, this seems doable. Just after confirmation or not.

Thank you, QA.

Hey @quidagis!

Yep, canton works great in docker so you should have no problems. Just make sure the ports are correctly exposed on the host (-p 15000:15000 or whatever).

As long as the ports don’t collide you can run as many instances of canton on a host as you like (or at least as many as your machine has resources for). Keep in mind that you can also run many canton participants and domains within a single process which may be easier to operate when developing.


1 Like

Thank you @david_padbury for that helpful reply,
and welcome to the forum … finally :smiley:

Just lurking through the Server and not only do I have two complete Canton installs, I have 2 networks bridges etc.

In terms of commercial use, or at least the statistics that the Canton Team is getting from installs, what is the more popular or potentially useful?

Canton-on-Metal or Canton-on-Docker?

Given your answer above, while it is doable, I’d like to go, either or.

Hey @quidagis. Did you use docker-compose for your canton setups as that would explain the many bridge networks?

I’d expect most will just use the docker image as it lets us manage the dependencies required to run canton. Today that’s really only the jvm but that will ensure it always has the right version. Plus for deployments like k8 a docker image is just more convenient. Keep in mind on Linux the docker canton instance is just a normal process, just one that’s a fair bit more isolated.

The main reason to run “on metal” would be to use your own jvm or customize it in someway we don’t. Or of course if you’re just more familiar with operating jvm based apps vs using docker.

Either way it is just the same canton app.


Thanks for context :+1:t2: @david_padbury

Re Docker-Compose, I did, although I think there is also an odd interfaces config, as I have 2 C Class IPs allocated to the one MAC interface + Docker IP.

Good point re version sanity by using Docker, but I will rm -f docker* and run lean.