How to deploy a web application to remote on premise IIS server

Ravindra Shukla 116 Reputation points
2021-07-14T10:12:49.557+00:00

Hello,

I am using MSDeploy in my Azure pipeline to deploy the web application on the on-premise IIS server. I am using deployment group for the same.

But in my case, the agent which I installed from deployment group resides on one on-premise windows server and my IIS server is different.(My agent is running on one machine and IIS is on another machine, both are on-premise machines)

So I need to deploy the web application using MSDeploy to that IIS server via the deployment group.

Is this possible, if yes, could you help to know how to do this?

Thank you.

Not Monitored
Not Monitored
Tag not monitored by Microsoft.
37,798 questions
0 comments No comments
{count} votes

3 answers

Sort by: Most helpful
  1. Bruce Zhang-MSFT 3,741 Reputation points
    2021-07-15T02:25:26.547+00:00

    Hi @Ravindra Shukla ,

    According to my understanding, you want to deploy application to remote IIS through MSDeploy. Is it right?

    There are three points.

    • Install MSDeploy on the remote server.
    • Create a local user which will be used by MSDeploy to publishing application.
    • Package application to be a folder or a zip file.

    Running the MSDeploy command with msdeploy.exe. The command line likes this:

    D:>"C:\Program Files (x86)\IIS\Microsoft Web Deploy V3\msdeploy.exe" -verb:sync -source:iisApp="D:WebApplication" -dest:iisApp="Default Web Site/WebApp",ComputerName="https://server:80/MsDeploy.aspx",UserName='ServerUser',Password='password',AuthType='Basic' -allowUntrusted  
    
    • -source:iisApp="" means directory with application to deploy.
    • -dest:iisApp="" means target application in IIS.
    • ComputerName="" means the target server with IIS where application will be placed.
    • UserName, Password used to perform deploy. It is important.
    • AuthType="" means the type of authentication. It can be NTLM and Basic.

    If the answer is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our  documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    Best regards,
    Bruce Zhang

    0 comments No comments

  2. Ravindra Shukla 116 Reputation points
    2021-07-15T08:05:40.787+00:00

    Hi @Bruce Zhang-MSFT

    Thank you for your reply.

    Yes I want to deploy a web application from Azure pipeline to on-premise IIS server using MSDeploy. So to have connectivity between Azure and on-premise environment, I need to have an self-hosted agent installed on one of the on-premise windows host and with the help of that I need to deploy the web application on IIS server, which is different host in on-premise environment.

    Right now I am using deployment group in my release-pipeline.

    I hope that my scenarios is clear.

    So I would like to know whether this is possible to achieve or not. If yes, then please suggest how can I do this.

    Thank you


  3. Ravindra Shukla 116 Reputation points
    2021-07-16T06:56:19.697+00:00

    Hi @Bruce Zhang-MSFT
    Thank you for your reply.

    I tried to add "azure" tag to this as you suggested, but its not accepting, its giving me a message like this "The following tags do not exist, and you don't have permissions to create new ones: azure"

    Could you please tell me which is the correct tag for azure, so that I can add it?

    Thank you.