Github Action for Azure Python Webapp: Failed to fetch credentials from Publish Profile

后端 未结 2 1212
不知归路
不知归路 2021-01-27 02:27

I\'m getting the error on above scrrenshot while Deploying the Azure WebApp to Azure by Github Actions. I have tried disconnecting and connecting the WebApp multiple tim

相关标签:
2条回答
  • 2021-01-27 02:58
    1. Go to WebApp in Azure Portal and download publishing profile.You would get someting similar to the below.

      <publishProfile profileName="[app-name] - Web Deploy" publishMethod="MSDeploy" publishUrl="waws-prod.publish.azurewebsites.windows.net:443" msdeploySite="[app-name]" userName="$[app-name]" userPWD="***" destinationAppUrl="http://[app-name].azurewebsites.net" SQLServerDBConnectionString="" mySQLDBConnectionString="" hostingProviderForumLink="" controlPanelLink="http://windows.azure.com" webSystem="WebSites">
          <databases />
      </publishProfile>
      <publishProfile profileName="[app-name] - FTP" publishMethod="FTP" publishUrl="ftp://waws-prod.ftp.azurewebsites.windows.net/site/wwwroot" ftpPassiveMode="True" userName="[app-name]\$[app-name]" userPWD="***" destinationAppUrl="http://[app-name].azurewebsites.net" SQLServerDBConnectionString="" mySQLDBConnectionString="" hostingProviderForumLink="" controlPanelLink="http://windows.azure.com" webSystem="WebSites">
          <databases />
      </publishProfile>
      <publishProfile profileName="[app-name] - ReadOnly - FTP" publishMethod="FTP" publishUrl="ftp://waws-prod.ftp.azurewebsites.windows.net/site/wwwroot" ftpPassiveMode="True" userName="[app-name]\$[app-name]" userPWD="***" destinationAppUrl="http://[app-name].azurewebsites.net" SQLServerDBConnectionString="" mySQLDBConnectionString="" hostingProviderForumLink="" controlPanelLink="http://windows.azure.com" webSystem="WebSites">
          <databases />
      </publishProfile>
      
    2. Change the publishing url at the first publishing profile for Web-Deploy to [appname].scm.azurewebsites.net instead of

      waws-prod.publish.azurewebsites.windows.net

    3. Go to Github and go to the repository.

    4. Go to the respective workflow yml file in .github/workflows and look for ${{ secrets.<SECRET_NAME> }}. Remember the <SECRET_NAME>.

    5. Go to settings > secrets and click on 'update' button respective to the secret name you remember from above step.

    6. Paste the XML code inside Value and click 'update secret'.

    7. Go to 'Actions' and select the failed workflow run and click 're-run jobs'.

    Now your Web Zip Deploy should be succesfull.

    0 讨论(0)
  • 2021-01-27 02:59

    For my case, i would like to add to the above answer that you need to add an app setting called WEBSITE_WEBDEPLOY_USE_SCM and set true. (I am using linux for my app service) and get publish profile. You will notice that the publish profile will automatically change waws-prod.publish.azurewebsites.windows.net to [example-app].scm.azurewebsites.net.

    TLDR;

    1. Set WEBSITE_WEBDEPLOY_USE_SCM = true in app settings
    2. click on get publish profile button to get an updated publish setting.
    0 讨论(0)
提交回复
热议问题