-
-
Notifications
You must be signed in to change notification settings - Fork 4.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Setting up remote interpreter in PHPStorm - documentation #951
Comments
Hi
The env-example file already has the |
Hi, this guide is for Ubuntu Linuxu, unfortunately I do not know where to
find this IP adress in os x :(
On Fri, Aug 11, 2017, 11:58 Chris Hodgson ***@***.***> wrote:
Hi
I'm struggling to find the DOCKER_HOST IP
docker ps -a returns several active containers including
laradockstoryboard_workspace. When i type ifconfig docker0 from OSX
command line it returns an error ifconfig: interface docker0 does not
exist
The env-example file already has the DOCKER_HOST_IP set to 10.0.75.1 but
this doesn't work when I add it to a deployment in PHPStorm
thanks
chris
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#951 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AGVQcM0rl_rYsGMi2EFpzSxUq89s9yAZks5sXCXTgaJpZM4NfFba>
.
--
S přátelským pozdravem
*Lukáš Benke*
mobil: 739 260 256 | e-mail: benke@akon.cz <skvarkova@kamvbrne.cz>
*AKON Česká republika, s.r.o.*
Bayerova 588/16, 602 00, Brno
tel./fax: 548 211 210
KamvBrne.cz <http://www.kamvbrne.cz/> | KamvPraze.cz
<http://www.kamvpraze.cz/> | Akon.cz <http://www.akon.cz/>
|
I follow the procedure to the letter and everything worked. I did want to configure PHPUnit to run trough the editor so there is a few extra step. Languages & Frmeworks > PHP Languages & Frmeworks > PHP > test Frmeworks Enjoy ! |
@mpoiriert Amazing, worked for me |
This article was helpful to me too: http://webandapp.fr/blog/2017/09/where-is-my-database-host/ After updating Docker recently, by "Docker" setting in PHPStorm no longer worked and I realized that the docker-compose setting is supposedly the preferred one and works. |
This is useful for Mac users: |
My solution: laradock/.env
PhpStorm settings:
|
Hi 👋 this issue has been automatically marked as |
Hi again 👋 we would like to inform you that this issue has been automatically |
Info:
$ docker --version
): Docker version 17.03.1-ce, build c6d412e$ git rev-parse HEAD
): b9b9d52Issue:
Hello, this is not issue per se, but after 4 hours of fiddling around, I've finally been able to correctly setup remote interpreter on Ubuntu 17.04 - including finding docker host ip, setting WORKSPACE_INSTALL_WORKSPACE_SSH to TRUE (ha, that one was nasty), correcting permissions on workspace/insecure_id_rsa etc. I'm willing to document this process and send pull request with updated documentation, my question is, if you are interested in this.
FOR ANYONE COMING HERE
Process is as follows:
Find your Docker Host IP
Open terminal, run ifconfig and look for docker0 interface, note the IP address. Example output:
docker0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500 inet === IP IS HERE => 172.17.0.1 netmask 255.255.0.0 broadcast 0.0.0.0 inet6 fe80::42:7aff:fe74:e3dc prefixlen 64 scopeid 0x20<link> ether 02:42:7a:74:e3:dc txqueuelen 0 (Ethernet) RX packets 19980 bytes 1627092 (1.6 MB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 25136 bytes 34818849 (34.8 MB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
Enable SSH in workspace
set WORKSPACE_INSTALL_WORKSPACE_SSH to true:
WORKSPACE_INSTALL_WORKSPACE_SSH=true
this is important, otherwise, you will get connection refused errorSet found Docker Host IP
set DOCKER_HOST_IP variable to found ip in .env :
DOCKER_HOST_IP=${FOUND_IP} //e.g. 172.17.0.1
Fix permissions on ssh keys
For me, the pregenerated .ppk files were not working (corrupted format error message in PHPStorm), so i used the
${LARADOCK_FOLDER}/workspace/insecure_id_rsa
, but before you can do that, you need to fix the permissions, othwerwise, they will get ignored by ssh. They should be 0600. You can do that with following command:chmod 0600 ${LARADOCK_FOLDER}/workspace/insecure_id_rsa
Set up deployment in PHPStorm
In PHPStorm, go to
Settings -> Build, Execution, Deployment
add a new SFTP deployment. Set it as follows:${LARADOCK_FOLDER}/workspace/insecure_id_rsa
Click Test SFTP Connection - should work.
Set up the remote interpreter in PHPStorm
Settings -> Languages & Frameworks -> PHP
You should be all set
The text was updated successfully, but these errors were encountered: