Trying to create my .cspkg Azure package file, but getting an error "Need to specify the physical directory for the virtual path..."

StackOverflow https://stackoverflow.com/questions/17553091

  •  02-06-2022
  •  | 
  •  

Frage

When I try to package my Azure web app (to create the .cspkg and .cscfg files), I get the following error in my ServiceDefinition.csdef file:

Need to specify the physical directory for the virtual path 'AzurePOCWebRole/' of role AzurePOCWebRole

Here's my .csdef file:

enter image description here

I'm assuming the error is referring to my <Site name="AzurePOCWebRole"> piece. I try adding physicalDirectory to <Site name="AzurePOCWebRole" physicalDirectory="../AzurePOCWebRole">:

enter image description here

And try to create the package again, but I get the same error and it reverts that change I just made back to <Site name="AzurePOCWebRole">:

enter image description here

QUESTION: What can I do to resolve this error and create my package?

War es hilfreich?

Lösung

I was editing the "automatically generated" version of ServiceDefinition.csdef, which wasn't apparent because it didn't indicate it wasn't the actual file, so whenever I rebuilt, it reverted this file back to the original ServiceDefinition.csdef's file, which I WASN'T editing.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top