Development on local machine, production on remote web server - sync setup?

Hi,

 

I am a little confused about PhpStorm terminology.  I have a local development environment on my MAC Catalina, with PhPStorm 2021.

My local webserver apache is set so that I type mysite.test in my browser and it is served on my local machine.

That site root is /Users/Me/Sites/mysite

The actual production server is via digitalocean, accessed by http://mysite.com, with remote folder /var/www/mysite. In PhpStorm I can browse the remote folder structure via its SFTP.

WHen PhpStorm asks for 'webserver' related info, does it need to know about my local apache server, or does it only want my remote server?

I am trying to get things set up, so that I can also run xdebug and debug locally, and for that I imagine the local apache server will come in to play. But for now, just trying to get the local-remote relationship set so I can do local/remote comparisons, syncs, etc.

thanks

4 comments
Comment actions Permalink

Hi there,

WHen PhpStorm asks for 'webserver' related info, does it need to know about my local apache server, or does it only want my remote server?

Where does it asks for that? What context? Share a screenshot please.

  • If this is about debugging... then provide local path/web server info.
  • If it's about deployment ... then it sounds like you have set that up already. But yes -- web server for deployment would be the URL that you use to open.
    P.S. You may also have a local Deployment entry (In Place deployment when no copying will be done at all). Useful when you want to use "Open in Browser" or alike functionality and so the IDE uses local URLs.

I would suggest checking these links first and then ask specific questions (with details/screenshots) if you will have any:

1
Comment actions Permalink

Without knowing what exactly IDE is asking, I assume it means your local web server: that is if you want to debug your site locally.

0
Comment actions Permalink

Hi, I seem to have things set up ok. In my case, I chose the option that I have files locally, with a remote web server, then I specified the server mappings between local and remote. 

Now I just have to figure out how to get debugging working on local setup so that I can degug things like webhooks! I tend to find it very difficult to debug stripe, mailchimp, etc webhooks during dev, and hoping there is an easy way to run my site locally and achieve this level of debugging.

 

thanks

0

Please sign in to leave a comment.