question

Ryan Quey avatar image
Ryan Quey asked Erick Ramirez commented

Can a DSE node be linked to OpsCenter with both running in docker containers?

I was able to successfully start up a DSE Ops Center docker container, and then subsequently link a DSE server docker container to it following the instructions here. However, is there a way to go in the reverse direction with a pre-existing DSE server container, and then link the DSE OpsCenter to it?


Use case would be for example, if you have DSE server and OpsCenter containers already running, and then the OpsCenter gets messed up or goes down for whatever reason, and you have to remove it. I can start OpsCenter again doing `docker run`, but now they aren't linked. Do I have to now stop and remove the DSE Server container as well so that I can link it again?


I'm sure there must be a way to link a preexisting DSE Server to a new OpsCenter but am just having a hard time finding how to do that.

docker
10 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

@brasco --Donnie Roberson-- avatar image
@brasco --Donnie Roberson-- answered Ryan Quey commented

Hi @Ryan Quey

The only way I can think of is to export OPSCENTER_IP=<opscenteripaddress> as a persistent variable maybe in the /entrypoint.sh. Then restart the container and the entrypoint.sh will pick up the ip address and run

https://github.com/datastax/docker-images/blob/master/server/files/entrypoint.sh.ftl#L104


1 comment Share
10 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Ryan Quey avatar image Ryan Quey commented ·

Does that mean that this is not a normal thing to do? What is the normal thing to do if we need to restart OpsCenter? Or is it not normal to use Docker in the first place?

0 Likes 0 ·
Erick Ramirez avatar image
Erick Ramirez answered Erick Ramirez commented

@Ryan Quey Container links were deprecated some time ago in Docker. I suggest you use regular IP addresses for communicating between DSE nodes and OpsCenter so it just works by design. It has the added benefit of being easier for you to troubleshoot problems between nodes without having to worry about issues with the containers themselves. Cheers!

2 comments Share
10 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Ryan Quey avatar image Ryan Quey commented ·

Thanks for this comment, this is helpful. So is there a particular reason this is the recommended approach from the Datastax docker-images documentation? (See here for when starting a DSE container or here for when starting Studio for example). Is it just something that DSE is still migrating away from?

0 Likes 0 ·
Erick Ramirez avatar image Erick Ramirez ♦♦ Ryan Quey commented ·

Unfortunately, that document is obsolete and your post here has prompted @@brasco --Donnie Roberson-- to revise it really soon. Cheers!

0 Likes 0 ·