Using the development methodology defined in the picture below (for more details, see Gonzalo Ruiz’s blog post here), our team spends a lot of time exporting unmanaged solutions from the Integration Development / Configuration environment (B) to our development environments (A), exporting and importing our “transport solutions”.
With the master solution growing in size, it takes more and more time to export, import and publish it every time. My colleague Jean-Francois Fortin and I worked on a very simple console application that automates the process of exporting and importing CRM solutions from one organization to another. Since then, it’s been transformed into a nice looking tool with a GUI (yes, we are that nice!). You can download the executable and the source code on the CodePlex project. The UI version of the application is the recommended and default download. Configuration is straight forward.
If you are using the Console version (older release), make sure you read the user guidelines below. All you have to do if you are not a developer is download the executable and edit the configuration file to point to your environments and solutions.
The menu is self-explanatory:
It should be noted that currently only unmanaged solutions are supported for import. If a timeout occurs during a solution import, the program polls the server every 10 seconds to see if it has finished the import task. To avoid a timeout during publish all customizations or other operation, set the ServiceTimeout, configuration parameter to a reasonable time (default is 2 minutes).
During import, the file matching your solution name which has the most recent time stamp and not containing managed.zip in its filename is imported.
During export, the version number of the solution is appended, as per the CRM default export filenames.
For now, this only work for Microsoft Dynamics CRM on Premise.
Once compiled, you can modify the Crm.Utilities.SolutionsDeploymentTool.exe.config file in the bin directory to change the values for the source and destination organizations or App.config before compilation.
The name of the organization to export from. There can be several organizations on a server, so with this parameter you can select which one to export from.
The URL of the server to export from. Include the http:// prefix and the port number if necessary.
The name of the organization to import to. There can be several organizations on a server, so with this parameter you can select which one to import to.
The URL of the server to import to. Include the http:// prefix and the port number if necessary.
The value of the default CRM organization service timeout value in minute. If left blank, timeout will be set to 2 minutes.
These are the solution(s) to export and later import. They are semi-colon separated.
This is the folder the solutions will be exported to and imported from. There should be a trailing slash.
This parameter is optional (it can left blank). It can be the active directory domain on which your username is valid.
This parameter is optional (it can left blank). This is the active directory user name used to log on to the server.
This parameter is optional (it can left blank). It is not encrypted (saved in plain-text). This is the password matching the username in the previous parameter.