Publish-AzWebApp: Could not find a part of the path for mac os file system

rishi g 0 Reputation points
2023-02-16T21:26:58.6133333+00:00

Hello,

So this question seems to have a fix for Windows machines but there hasn't been one specific for Mac.

When I run the Powershell Publish-AzWebApp command for deploying a war file to App service with an Path from my local machine, the error is as follows:

Publish-AzWebApp: Could not find a part of the path '/Users/rishig/Downloads/app/filename.zip'.

The input command entered looks like this :

Publish-AzWebapp -ResourceGroupName SampleName -Name ZNAME -ArchivePath /Users/rishig/Downloads/app/filename.zip

I've verified the file path on my local machine to be accurate. Is there something missing in the filepath parameters or the way it's structured or anything else at all ?

Thanks in advance for any help in regards to this.

PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,888 questions
Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
8,523 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Limitless Technology 44,671 Reputation points
    2023-02-17T11:17:30.6166667+00:00

    Hello there,

    According to the exception, it indicates that there is no related path in the Azure. If it is possible, we could remote debug Azure Web Apps. Then we could get the file path. After that we could use the Azure kudu(https://yoursite.scm.azurewebsites.net) tool to check whether the path is existing.

    If the file path is not existing, we could drag the folder to the kudu tool directly or we also could publish the folder with Visual Studio. After that, it should work.

    Similar discussion here https://learn.microsoft.com/en-us/answers/questions/46900/azure-app-service-not-able-to-find-root-folder-pat

    Hope this resolves your Query !!

    --If the reply is helpful, please Upvote and Accept it as an answer–

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.