Setting up docker reference in .NET project


#1

I am fairly new to Docker and I am trying to wrap my head around this, and before I go too far down this rabbit hole, I figure I’d ask to see if it is possible to do in the first place.

I have Docker running on my Windows machine. I have set up a simple C# console app using .NET and have set up Docker containerization support in the project.

I now have a Dockerfile and a docker-compose.yml file added. It appears in the Dockerfile, that I can add dependencies, and in the docker-compose I can add a dependency for my console app to depend on another docker container, therefore setting up the corresponding dependency chain and allow the two pieces to talk to one another?

Has anyone went about setting this up so that it can install the ODM docker file as part of a dependency of the console application so that I can call the ODM API via command line? If so, are there any resources that you can point me to in order to try and get this set up in such a manner?

Please excuse my ignorance on the subject and thanks in advance!


#2

Hey @nlraley :hand: have you checked out the docker docs? https://docs.docker.com

I think you are trying to understand how docker works, which might or might not be the best way to use ODM in your project. We also expose an API via NodeODM (https://github.com/OpenDroneMap/NodeODM) which might be a better way?


#3

I have read through a bit of them, and have a basic understanding of how a simple Docker container works. What I don’t understand is how to reference another docker container within a Visual Studio project that has been dockerized.

Has anyone done that? Ideally I just want to run a console app that can call the base ODM container with parameters that I feed it. Does that make sense?