DEV Community 👩‍💻👨‍💻

DEV Community 👩‍💻👨‍💻 is a community of 968,873 amazing developers

We're a place where coders share, stay up-to-date and grow their careers.

Create account Log in
Cover image for #Tip Use local Azure Storage emulator in Remote Containers
Christopher Maneu
Christopher Maneu

Posted on • Originally published at

#Tip Use local Azure Storage emulator in Remote Containers

I LOVE Remote Development Extensions for Visual Studio Code. It allows me to simply pack all my technical stack in one docker container, while getting me everything I need to run and debug things.

Everything, this includes localhost, right?

Ehmm.. that depends! This morning, I was doing different things with Azure Functions SDK for 25 days of serverless, and for that I needed to access the local Azure Storage Emulator, the one on my local machine - not within a Docker container.

How can I possibly access local resources - who are neither on Internet or within another container - from a container?

3 magic words

host.docker.internal. That's all you need within your container to access your "real" localhost, and everything hosted on it. Like my Azure Storage Emulator :). With that bit of magic, I was able to replace the usuel local connection string UseDevelopmentStorage=true; by the following :


Et voilà! I'm now able to use the benefits of Remote Containers development while using all my local hosted tools, including the Azure Storage Emulator :)

Top comments (0)

🌚 Friends don't let friends browse without dark mode.

Sorry, it's true.