0
votes

I'm deploying an IIS Web App with IIS Web App Deploy Task in Azure DevOps Release Pipeline. This works good but don't set the correct application pool. I'm trying it with set a Parameter in Parameters.xml or as -setParam to the Task. But this doesn't change anything. The googled Solutions didn't help. How can I manipulate the Application Pool during deployment? Thanks.

EDIT

In reference to this answer I configured the parameters.xml and pipeline like this. (appHostConfig instead of appPoolConfig hadn't changed anything)

parameters.xml

<parameters>
    <parameter name="Parameter 1" description="Full site path where you want to install your application (for example, Default Web Site/Application)." defaultValue="Default Web Site/MyApplication" tags="IisApp">
        <parameterEntry kind="ProviderPath" scope="iisApp" match="Default\ Web\ Site/MyApplication" />
    </parameter>
    <parameter name="Parameter 2" description="Enter the name of the application pool." defaultValue="MyAppPool" tags="AppPoolConfig">
        <parameterEntry kind="ProviderPath" scope="appPoolConfig" match="MyAppPool" />
    </parameter>
    <parameter name="IIS Web Application Name" description="Enter the name of the website." defaultValue="MyApplication" tags="IisApp" />
    <parameter name="Application Pool" description="Enter the name of the application pool." defaultValue="MyAppPool" tags="AppPoolConfig" />
</parameters>

Set the website in IIS Web App Deploy Task (results to -setParam:name='IIS Web Application Name',value='Default Web Site/MyApplication')

Website / Application

Set the Application Pool parameter in IIS Web App Deploy Task

Application Name

1

1 Answers

1
votes

Set Application Pool in IIS Deployment with Azure Release Pipeline

Since you do not share how did you set the Parameter in Parameters.xmland -setParam to the Task, I am not sure if you correct set the Parameter.

You could check this and this thread for some more info.

Anyway, for azure devops, there is an option Application Pool for the task IIS Web App deployment, which we could set the Application Pool:

enter image description here

Besides, the IIS Web App deployment is currently deprecated, MS recommends the task WinRM - IIS Web App Management.

Update:

There is an option Configuration type, select IIS Website:

enter image description here

Please check this document for some more details.

Hope this helps.