In Server App-V, we wanted to provide a way to make your virtual packages customizable for you; a number of settings you can create based on your needs. In the next few moments, you will be introduced to deployment configuration items, a very unique feature of Server App-V that makes your deployment scenarios flexible.
Chapter 1 – DCI 101
Imagine you just sequenced a server application and created a package with the Server App-V Sequencer. The virtual applications in the package will do something when they are deployed and run. They may try to connect to a database server, listen on a port, access a specific machine or use specific credentials to access some resources. If we don’t give you a chance to control the settings of your virtual applications, they will always try to connect to the same database machine, listen on the same port and use the same credentials that you used on the sequencing station.
A basic scenario will make this clearer: I sequenced an application and during sequencing I configured my application to connect to database X. When I deploy the Server App-V package, the application will always try to connect to database X, unless I do something to change that. Over the next few years, I might want to deploy the very same package to hundreds of machines. How can I change the database that my application connects to?
The Server App-V Sequencer allows you to detect or even add environment specific application settings at sequencing time which can then be customized at deployment time. These settings are called “Deployment Configuration Items”. At the end of the sequencing, the last screen of the sequencer will allow you to see automatically detected deployment configuration items. From the same page, you can search and add additional deployment configuration items based on the needs of your application. For example; you can search for the string “database” which will look in all the places applications typically store configuration for references to that string. One of those references could conceivably be a database connection string for which you can create a deployment configuration item. By changing this item at deployment time, you can customize the application to point to the database that is appropriate for the environment that you are trying to deploy to. Having deployment configuration items will give you great flexibility during deployment time because you will be able to deploy the same package with different settings to each machine.
Chapter 2 – Show time
Now that we know what deployment configuration items are, let’s take a look at an example.
I sequenced the Ipswitch File Transfer (WS_FTP) application which uses IIS components, a local user, a couple of Windows Services, etc.. In the last page of Server App-V Sequencer, you will see the following screen which is all about deployment configuration items:
First, you will notice that the deployment configuration items generated are categorized into areas such as IIS, Local Users and Groups, Manual and Virtual Services. This is not a complete list but it covers the most popular ones. Let’s take a look at a couple of them and try to understand what they mean.
If you look at the second IIS entry:
This is classic IIS identity information. During the sequencing process, Server App-V IIS subsystem captures information and creates deployment configuration items for the information. In this case, the application creates a user identity and sets it to “IPS_wsftp_admin”. IPS_wsftp_admin is a local user that’s also created during sequencing. Now, what happens if we want to change the value of IIS user identity to something else for our deployment scenario? No problem… We can easily do that since we have the deployment configuration item for the user identity. I will show you how to modify these values in the next section but for now let’s take a look at another example:
In the image above, we notice that Server App-V Sequencer LUG (local users and groups) subsystem captures information about a local user during the sequencing process. WS_FTP creates a local user on the machine and we expose the password for that local user as a deployment configuration item. However, notice that there’s no value associated with this deployment configuration item. Passwords are confidential information, we will ask you to provide the password you want to create the account with during deployment time. Having the ability to enter the password as a deployment configuration item gives you the power of deploying this package to servers which have different password policies since you don’t have to stick to a single password now!
There’s also a “Manual” deployment configuration items section in the Server App-V Sequencer. As a user, you can create your own deployment configuration items by using the “Add Deployment Configuration Item” button on the right side of the sequencer page. Server App-V sequencer already uses subsystems such as IIS, LUG, Virtual Services to generate automatic deployment configuration items but in most cases you will want to create very application specific deployment configuration items. After I clicked “Add Deployment Configuration Item” you will see a new window like the one below:
You can do a search in this window to create deployment configuration items. For example, I used “DB*” to find everything starts with the string “DB”. I can add DBDataDir as a deployment configuration item and change the database data directory’s value during deployment time based on my needs.
Chapter 3 – Playground
We just learned what deployment configuration items are and how to create and use them. Now, let’s take a look at how this fits into SCVMM2012. In SCVMM 2012, as part of the VM template creation workflow, you create an Application Profile which includes the Server App-V package along with its deployment configuration items, all surfaced in the VMM UI
You can create as many application profiles as you want and use the very same Server App-V package with different deployment configuration items. This feature gives you great flexibility to customize your deployment scenarios. All you need to do is to enter the deployment configuration items for a specific environment and save it in an application profile. You can then later use the application profile in a service template to deploy your instances with a one button operation. The deployed instance will have the Server App-V package configured with the settings you customized from the SCVMM UI. If you are not familiar with SCVMM 2012 and application profiles, I would recommend that you download the SCVMM 2012 Beta and play with it. Server App-V along with SCVMM 2012 is designed to make deployment of applications as easy as pie.
Chapter 4 – Automation
Server App-V Sequencer has functionality to automatically detect deployment configuration items. Here is a list of deployment configuration items detected by each Server App-V subsystem
- COM subsystem searches for DCOM and COM+ credentials.
- IIS subsystem searches for web site bindings, application pool settings and IIS component credentials. You can control the port and IP address of a website by using deployment configuration items.
- LUG subsystem searches for new local users and groups and creates deployment configuration items for their credentials.
- Virtual Services subsystem searches for new services added to the system during sequencing process and creates deployment configuration items for the service credentials. By this way, you can run a service as Network Service or Local System or a domain user account!
I hope you enjoyed the blog post. Next time you sequence an application, pay special attention to deployment configuration items and customize your package settings based on your needs. We are looking forward to get your feedback!
Emre Kanlikilicer – Software Design Engineer II – Microsoft Server Application Virtualization Team.