Azure App Service can't find .net sdk

Chris 0 Reputation points Microsoft External Staff
2023-09-06T17:43:33.7833333+00:00

I am publishing my .Net 6 app to an Azure app service using a ADO pipeline. The application fails to start. From everything I've read, the "missing SKD" and startup file is about where the files are placed on the app server, yes? I just have no idea how to fix that.

I see the following errors in the log stream

2023-09-06T15:32:46 Startup Request, url: /api/logstream/, method: GET, type: request, pid: 80,1,8, ScmType: VSTSRM

/home/LogFiles/2023_09_06_pl1sdlwk000BJY_default_docker.log (https://hrchangemanagement.scm.azurewebsites.net/api/vfs/LogFiles/2023_09_06_pl1sdlwk000BJY_default_docker.log)

2023-09-06T15:26:20.645797610Z The application 'HR Taxonomy Change Management.dll' does not exist.

2023-09-06T15:26:20.648177180Z * You intended to execute a .NET SDK command:

2023-09-06T15:26:20.654164456Z No .NET SDKs were found.

2023-09-06T15:26:20.654192957Z

2023-09-06T15:26:20.654198857Z Download a .NET SDK:

2023-09-06T15:26:20.654203757Z https://aka.ms/dotnet-download

2023-09-06T15:26:20.654208458Z

2023-09-06T15:26:20.654212858Z Learn about SDK resolution:

2023-09-06T15:26:20.654217358Z https://aka.ms/dotnet/sdk-not-found

The deployment from devops completes successfully and here are the build and deploy tasks:


- task: VSBuild@1
  inputs:
    solution: '$(solution)'
    msbuildArgs: '/p:DeployOnBuild=true /p:WebPublishMethod=Package /p:PackageAsSingleFile=true /p:SkipInvalidConfigurations=true /p:PackageLocation="$(build.artifactStagingDirectory)"'
    platform: '$(buildPlatform)'
    configuration: '$(buildConfiguration)'

- task: VSTest@2
  inputs:
    testSelector: 'testAssemblies'
    testAssemblyVer2: |
      General\Exceptions.Handling.Tests\bin\Release\Exceptions.Handling.Tests.dll
      !*testhost.dll 
      !**\*testhost*.*
      !**\Microsoft*.dll
    platform: '$(buildPlatform)'
    configuration: '$(buildConfiguration)'

- task: AzureWebApp@1
  inputs:
    azureSubscription: 'HR Data Governance(2442165c-339d-4e83-a443-a6583c372938)'
    appType: 'webAppLinux'
    appName: 'HRChangeManagement'
    deployToSlotOrASE: false
    resourceGroupName: 'HRChangeManagement'
    package: '$(Build.ArtifactStagingDirectory)/**/*.zip'

- task: PublishBuildArtifacts@1
  inputs:
    pathToPublish: $(Build.ArtifactStagingDirectory)
    artifactName: MyBuildOutputs
Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
8,963 questions
{count} votes

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.