Access docker's built-in php server on Host

0

Well, I've been studying docker here and along with that I want to create a php server (by its built-in server) and then access that server from my HOST machine.

I ran the following command:

docker run -it -p 8080:8080 -v "D:\git\slim-saa:/home" -w "/home" my_opensuse_slim php -S localhost:8080 -t public public/index.php

After running this command, the server runs normally:

Portsandvolumesaremappednormally(Ithinkkk):

ButwhenIgotomymachineandaccessthelocalhost:8080,Icannotaccessanything:

Do you have any idea what I did wrong?

    
asked by anonymous 26.11.2017 / 01:00

1 answer

0

I found the problem but not the final solution. It occurred that my container-host mapping was right, problematic even was the way I was / am using the php embedded web server. I installed php + apache normally in the image and when I got the web server everything worked.

    
30.11.2017 / 18:28