将.NET Core应用程序部署到Azure App Service时出错

时间:2016-11-20 21:37:15

标签: azure asp.net-core azure-web-sites

我正在从GitHub部署.NET核心应用程序到Azure App Service并收到以下错误:

  

使用的饲料:       https://api.nuget.org/v3/index.json D:\ Program Files(x86)\ dotnet \ dotnet.exe build" D:\ home \ site \ repository \ src \ MY_APP"   --configuration Release --no-dependencies --build-base-path" D:\ home \ site \ repository \ src \ artifacts" Microsoft(R)Build Engine   版本15.1.0.0版权所有(C)Microsoft Corporation。所有权利   保留。 MSBUILD:错误MSB1001:未知的开关。   [D:\ home \ site \ repository \ src \ MY_APP \ MY_APP.xproj]开关:   --build碱基路径

就I can tell而言, build-base-path 是一个有效的参数。

此应用程序部署正常。事实上,我甚至试图重新部署最后一次良好的部署,现在也失败了。

这是project.json:

{


"buildOptions": {
    "debugType": "portable",
    "emitEntryPoint": true,
    "preserveCompilationContext": true
  },
  "runtimeOptions": {
    "gcServer": true
  },
  "userSecretsId": "aspnet-rverbio-457D3F4C-1C63-4A4C-8D65-5EA4FA4EE5F9",
  "dependencies": {
    "Microsoft.ApplicationInsights.AspNetCore": "1.0.2",
    "Microsoft.AspNetCore.Authentication.Cookies": "1.1.0",
    "Microsoft.AspNetCore.Authentication.OpenIdConnect": "1.1.0",
    "Microsoft.AspNetCore.Diagnostics": "1.1.0",
    "Microsoft.AspNetCore.Mvc": "1.1.0",
    "Microsoft.AspNetCore.Mvc.TagHelpers": "1.1.0",
    "Microsoft.AspNetCore.Server.IISIntegration": "1.1.0",
    "Microsoft.AspNetCore.Server.Kestrel": "1.1.0",
    "Microsoft.AspNetCore.StaticFiles": "1.1.0",
    "Microsoft.Azure.DocumentDB.Core": "0.1.0-preview",
    "Microsoft.Extensions.Configuration.Abstractions": "1.1.0",
    "Microsoft.Extensions.Configuration.FileExtensions": "1.1.0",
    "Microsoft.Extensions.Configuration.Json": "1.1.0",
    "Microsoft.Extensions.Configuration.UserSecrets": "1.1.0",
    "Microsoft.Extensions.Logging": "1.1.0",
    "Microsoft.Extensions.Logging.Console": "1.1.0",
    "Microsoft.Extensions.Logging.Debug": "1.1.0",
    "Microsoft.Extensions.Options.ConfigurationExtensions": "1.1.0",
    //"Microsoft.IdentityModel.Clients.ActiveDirectory": "3.13.7",
    "Microsoft.IdentityModel.Protocol.Extensions": "2.0.0-beta6-207211625",
    "Microsoft.VisualStudio.Web.BrowserLink.Loader": "14.1.0",
    "System.IdentityModel.Tokens.Jwt": "5.1.0"
  },
  "frameworks": {
    "netcoreapp1.0": {
      "dependencies": {
        "Microsoft.NETCore.App": {
          "type": "platform",
          "version": "1.0.1"
        }

      },
      "imports": "dnxcore50"
    }
  },
  "tools": {
    "Microsoft.AspNetCore.Server.IISIntegration.Tools": {
      "version": "1.1.0-preview4-final"
    },
    "Microsoft.Extensions.SecretManager.Tools": {
      "version": "1.1.0-preview4-final"
    }
  },
  "publishOptions": {
    "include": [
      "wwwroot",
      "Views",
      "appsettings.json",
      "config.json",
      "web.config"
    ]
  },
  "scripts": {
    "precompile": [
      "powershell -f Download-Secrets.ps1"
    ],
    "prepublish": [
      "npm install",
      "npm run build"
    ],
    "postpublish": [
      "dotnet publish-iis --publish-folder %publish:OutputPath% --framework %publish:FullTargetFramework%"
    ]
  }
}

任何帮助都将不胜感激。

更新

我的一位同事用以下内容创建了一个global.json,部署工作正在进行中!

{
    "sdk": {
        "version": "1.0.0-preview2-003131"
    }
}

0 个答案:

没有答案