Skip to content

IIS virtual directory

Microsoft defines IIS virtual directories as follows:

A virtual directory is a directory name (also referred to as path) that you specify in IIS and map to a physical directory on a local or remote server. The directory name then becomes part of the application’s URL, and users can request the URL from a browser to access content in the physical directory, such as a Web page or a list of additional directories and files. If you specify a different name for the virtual directory than the physical directory, it is more difficult for users to discover the actual physical file structure on your server because the URL does not map directly to the root of the site. (learn.microsoft.com)

IIS virtual directory deployment requires an existing IIS website.

In order to deploy an IIS virtual directory, when defining your deployment process, select IIS virtual directory as the type of IIS deployment:

Deployment type

Next, set the name of the parent website.

Parent website name and virtual path

Parent website name should already exist on your deployment targets.

Parent website name and virtual path

The above settings after a successful deployment will look like this in IIS manager on your deployment target(s):

Parent website name and virtual path in IIS manager

Configuration transforms

fDeploy supports .NET XML Document Transform (XDT) for transforming configuration files during deployment. You can enable automatic transforms that detect *.Release.config and *.<Environment>.config files, and define additional custom transform rules.

Configuration transforms run after the package is extracted and before variable substitution.

For full details on transform syntax and configuration, see the Configuration transforms documentation.

Variable substitution

This section defines target files to perform variable substitution on. Files defined here will be modified by fDeploy Agent and searched for any variables matching the role and environment scope for a given deployment task.

Variable substitution

fDeploy agents will extract the package and replace any variables in the files you define in this section. The files will be parsed and variables replaced with the ones defined in your fDeploy project. Files listed here must be relative to the contents of the package. Make sure to separate the file names by using a new line separator (one file per line).

Phase timeout

Default: 60 seconds per phase. Range: 1–3600.

Virtual directory deployment runs two PowerShell phases (parent-website check, virtual directory upsert). The timeout you configure applies independently to each phase. If a phase hangs the PowerShell process tree is killed and the task log records the phase name with a _timeout suffix. Timeouts are contained to each deployment target; one target’s hang never extends another target’s budget.

Execute deployment

Once you are happy with the process definition, you can proceed with creating a deployment.

  1. Create a release
  2. Use the “Deploy to…” button to move on to environment selection
  3. Select your target environment
  4. Use the “Deploy” button

At this point, your deployment will be added to queue and executed based on FIFO principle (first in, first out). You will be taken to the deployment task summary where you can follow the progress of the deployment (the view will be short-polled and automatically updated).

Deployment queued

Once the deployment is completed with a status of success or failed, you can view the detailed task log by using the “deployment task log” tab:

Deployment task log