Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

KiberMath's avatar

How to configure PHPStorm to run PHPUnit tests in docker

Hello. I have server with docker on it. On the server i have compose.yaml with services i need for my app. And now if i want to run a test I can go to server, then "docker exec -it php bash" and in the container run phpunit. So i think i can do the same with phpstorm interface? I know how to do it if whole app is on my local computer. But cant understand how to do it if app in docker on the VPS. Please help...

I tried connect from phpstorm to docker. it connected, but it does not show me any of my containers... so i cant set php interpriter to run my tests..

0 likes
1 reply

Please or to participate in this conversation.