Set PHP path from host to docker container
I know this is a rather stupid question, but I have the following problem. I have been using Docker for over a year and an editor to modify my program which hosts as a volume.
I didn't install php because it only works inside containers like almost all my other server programs (e.g. sql, apache). now i have installed visual studio code and it cannot find php path to use intellisense.
I know that I can set the environment path inside my docker-compose or Dockerfile to set the environment for my container. but the container, if run is isolated from the outside, except for commands like docker cp.
Is it possible to set the path from my host machine to the container machine so the visual studio code can find PHP inside the container and use it for intellisense? or do I need to install php on my main machine? but that in my opinion would ruin the use of Docker containers.
for example in visual studio code config settings.json
"php.validate.executablePath": DOCKERCONTAINER/usr/bin/php
source to share
No one has answered this question yet
See similar questions:
or similar: