I am trying to deploy a mvc web application on server IIS which already exist so i need to deploy my packages on already created virtual directory (under default website) as shown in image 3 in attachment . Octopus server always create website on 80 port in IIS even after specified different bindings. And it give this error
Attempt 1 of 5 failed: Cannot create a file when that file already exists. (Exception from HRESULT: 0x800700B7)
Waiting for 3 seconds before retrying…
Retrying…
Web site is stopped. Attempting to start…
Attempt 2 of 5 failed: Cannot create a file when that file already exists. (Exception from HRESULT: 0x800700B7)
Waiting for 3 seconds before retrying…
Retrying…
Web site is stopped. Attempting to start…
Attempt 3 of 5 failed: Cannot create a file when that file already exists. (Exception from HRESULT: 0x800700B7)
Waiting for 3 seconds before retrying…
Retrying…
Web site is stopped. Attempting to start…
Attempt 4 of 5 failed: Cannot create a file when that file already exists. (Exception from HRESULT: 0x800700B7)
Waiting for 3 seconds before retrying…
Retrying…
Web site is stopped. Attempting to start…
start-webitem : Cannot create a file when that file already exists. (Exception
from HRESULT: 0x800700B7)
At C:\Octopus\Applications\QA\QuoteStar.TeamCity\79_27\Octopus.Features.IISWebS
ite_BeforePostDeploy.ps1:655 char:4
-
Start-Website $webSiteName
-
~~~~~~~~~~~~~~~~~~~~~~~~~~
- CategoryInfo : InvalidOperation: ( [Start-WebItem], COMExcept
ion - FullyQualifiedErrorId : InvalidOperation,Microsoft.IIs.PowerShell.Provid
er.StartItemCommand
Script ‘C:\Octopus\Applications\QA\QuoteStar.TeamCity\79_27\Octopus.Features.IISWebSite_BeforePostDeploy.ps1’ returned non-zero exit code: 1
Running rollback conventions…
Script ‘C:\Octopus\Applications\QA\QuoteStar.TeamCity\79_27\Octopus.Features.IISWebSite_BeforePostDeploy.ps1’ returned non-zero exit code: 1
The remote script failed with exit code 1
DeploySite on QA…
- CategoryInfo : InvalidOperation: ( [Start-WebItem], COMExcept
Also i am attaching the binding configuration.