3 回答

TA貢獻1895條經驗 獲得超7個贊
因為安裝了docker我本地已經沒有/usr/bin/php文件。
這時候,如果我需要使用php cli來執行一個php,如何操作?
我想,可以ssh進行php容器,然后在容器內執行 /usr/bin/php xxx.php
但是在phpstrom IDE中感覺使用起來不太方便。
然后我看到phpstorm有個 docker的plugin,需要配置個docker-machine
問題來了,我開發環境是ubuntu 16.04
$ docker-machine create -d none --url="tcp://0.0.0.0:2375" default
$ docker-machine env default
Error checking TLS connection: Error checking and/or regenerating the certs: There was an error validating certificates for host "0.0.0.0:2375": dial tcp 0.0.0.0:2375: getsockopt: connection refused
You can attempt to regenerate them using 'docker-machine regenerate-certs [name]'.
Be advised that this will trigger a Docker daemon restart which will stop running containers.
- 3 回答
- 0 關注
- 1222 瀏覽
添加回答
舉報