0

The scenario is like this:

I have a .net Core docker image that runs on a laptop, where other laptops should be able to access it, ususally on an ad hoc local network with no internet access.

On the server laptop it is just: http://localhost:23456

But when other laptops connects it is something like: http://192.168.1.12:23456

So I would like that when at app is started up on the server laptop on: http://localhost:23456 the app could resolve the hosts IP address and write:

"For client laptops connecting to this server use this address: http://192.168.1.12:23456"

2
  • This is what you're asking? docker container ip within a .net core application Commented Oct 22, 2020 at 10:05
  • 1
    This is something Docker intentionally hides from you. The linked question has several ways to get an address, but for this particular application the better answers come down to "pass it in as an environment variable". Commented Oct 22, 2020 at 11:04

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.