XebiaLabs | Continuous Delivery and Agile DevOps Tools

XebiaLabs Blog

Subscribe to XebiaLabs Blog: eMailAlertsEmail Alerts
Get XebiaLabs Blog via: homepageHomepage mobileMobile rssRSS facebookFacebook twitterTwitter linkedinLinkedIn

Blog Feed Post

Using the XL Deploy CLI to Update Properties Prior to Deployment

Have you ever wondered if you could modify the properties of one of the objects you are deploying just before the actual deployment from a CLI script? You can make last minute changes like this in the UI just before deployment.  We always tell people that anything you can do from the UI can be done from the CLI.  Let’s first see what this looks like from the UI.  Let’s say we have an environment “DEV” and an application “unixFile” as follows:

Screen Shot 2015-05-12 at 2.30.39 PM

We can then double click on the “folder1″ object to reveal the properties of this object and make changes before we deploy them.


Screen Shot 2015-05-12 at 2.31.07 PM

For example we can change the “Target Path” for the file from “/tmp/masterFolder” to “/tmp/blog/test” as follows:


Screen Shot 2015-05-12 at 2.31.34 PM

After doing the deployment we will notice that the files are deployed to the new folder.


Screen Shot 2015-05-12 at 2.32.21 PM

So that is fine, but what we want to do is the same thing with a CLI script.  In our script we will follow much the same process.  Below is a CLI script to do the same thing.


Screen Shot 2015-05-12 at 2.44.01 PM

Let’s look at what is happening here.  First we set some variables for the application and environment that we are going to be deploying to.  Then we start the deployment and generate the mapping.  This is the same as our first step above.  Now, before we actually kick off the deployment we will modify the “Target Path” of our deployed.  Once that is done we can create the deployment tasks and start the deployment.  To verify that our deployment went as expected we can have a look at the deployment in the UI under reports as follows:


Screen Shot 2015-05-12 at 2.52.51 PM

As you can see from the deployment log we were able to change the final deployment path.  You can use this process for changing the properties of any deployed during the CLI.


The post Using the XL Deploy CLI to Update Properties Prior to Deployment appeared first on XebiaLabs.

Read the original blog entry...

More Stories By XebiaLabs Blog

XebiaLabs is the technology leader for automation software for DevOps and Continuous Delivery. It focuses on helping companies accelerate the delivery of new software in the most efficient manner. Its products are simple to use, quick to implement, and provide robust enterprise technology.