Multiple Deploying Mappings

Hello, I'm new to phpstorm switching from netbeans.
I love phpstorm but one thing i miss:

  • I have a projekt and want to deploy an one server.
  • On the server are to versions of the web DEV and PROD
  • My server has two htdocs for www.server.de and dev.server.de


What can I do to switch the deploymend between this two path.
I tryed the mapping but its not working for me

13 comments
Comment actions Permalink

@James Antrim

As a workaround: you can create more than one deployment entry (even if it points to the same server) and then join them  into one group. When uploading, use that group and it will be processed for every deployment target in that group.

1
Comment actions Permalink

>It would also be really nice to have a save as copy function for PhpStorm servers, so that I don't have to reconfigure the settings every time I create an alias for the same real server / PhpStorm server.

There is a Duplicate button on toolbar: https://www.jetbrains.com/help/phpstorm/settings-deployment.html#toolbar

1
Comment actions Permalink

@James Antrim

Use right click menu or shortcut

1
Comment actions Permalink

Hello,

you have single server and single project directory, but two web roots, don't you? So you have no problems with upload and download of changes, but struggle with Show in browser and debug?

0
Comment actions Permalink

I have problems with live Editing, but that's not my question.

My Problem is that i can not have two diffentent Path to Upload on the same server. I don't know how to explame better.

I try again:

  • I have a simple HTML/CSS/JS-Projekt
  • want to upload it to a dev.server.com to test it in iphone etc. and show it to my custemer
  • want to upload it to www.server.com to bring it live.
  • the problem is, this are not two differnet servers, it is one server with different docroots


I don't want to make two Server-connections with the same username and password

0
Comment actions Permalink

As far as I understand your issue you have few choices here (but I doubt that you will be satisfied with any of them):

  • Normal approach: define 2 deployment entries and switch between them when required. NOTE: If you do not mark any of them as Default, then every time you invoke "Upload to..." you will be prompted what deployment entry to be used.
  • Weird approach (at least for me): manually change remote path mapping every time you need to upload to another root folder (e.g. "/httpdocs" for production and "/test" for development root)
0
Comment actions Permalink

thanx, but this is only a workround, i know.

i hobe jetbrains will implement this feature or have some tips

0
Comment actions Permalink

It will be much better if you could be a bit more specific -- it definitely helps while having conversation.

thanx, but this is only a workround, i know.

Workaround? Which one? Are you talking about having IDE asking you what server to use for uploading?

i hobe jetbrains will implement this feature or have some tips

Implement what exactly? Unfortunately I cannot make any decent conclusion based on this -- only guesses.

0
Comment actions Permalink

Seems like a few years have gone by on this thread but it was up there on the google results...

I think/hope he is talking about being able to deploy to the same local folder to multiple folders on the same server. PhpStorm allows me to create the mappings but the second/third/.. mappings from the same local folders are ignored.

I first ran into this same problem with the Joomla language folder structure. Joomla has two language folders for each instance: one in site/language and one in site/administrator/language. It would have been very convenient to be able to deploy the same local folder to both instance folders. I found a work around for this particular issue using Joomla means.

Today I ran into the same problem again in a different context. My university has several Joomla Instances on both the same server and across different servers. I would like to deploy the same local folders to multiple Joomla instances on the same server to test routing behavior in different Joomla instances with different routing settings

Specifically I would like to be able to deploy the same project/media folder to both server1/site1/media/my_project and server1/site2/media/my_project.

As stated above PhpStorm allows me to create the mappings for both server1/site1 and server1/site2, but the deployment only is carried out using the first folder mapping.

 

0
Comment actions Permalink

This seems like a really good idea independent of the current deployment problem, many thanks. :)

0
Comment actions Permalink

The more specific deployment targeting is really nice.

It would also be really nice to have a save as copy function for PhpStorm servers, so that I don't have to reconfigure the settings every time I create an alias for the same real server / PhpStorm server.

Copying PhpStorm servers would also be a tool to avoid the disadvantages regarding regrouping, reuse and inter-project use/visibility of PhpStorm servers which come as consequences of the design decision to subordinate PhpStorm servers to groups instead of just associating them with groups.

0
Comment actions Permalink

I don't see the Icon described by the link. PhpStorm 2019.2.3 Build #PS-192.6817.20, built on September 25, 2019



0

Please sign in to leave a comment.