p1c2u / vscode-docker-compose

Docker Compose Extension for Visual Studio Code
MIT License
18 stars 8 forks source link

Keep environment variables on command execution #33

Closed yeckey closed 5 years ago

yeckey commented 5 years ago

When setting the env parameter on child_process.exec() the parent's environment gets overridden. In order to pass down the parent's environment variables (like DOCKER_HOST) to the spawned process, process.env needs to be merged in with any new environment variables.

This should make this extension work for setups where DOCKER_HOST needs to be set (e.g. accessing Docker for Windows from within WSL). @dmlb2000 reported this before as issue #32.

p1c2u commented 5 years ago

/AzurePipelines run