【问题标题】:.net core aws eb deploy in Visual Studio 2015 cannot resolve dependencyVisual Studio 2015 中的 .net core aws eb deploy 无法解析依赖关系
【发布时间】:2016-11-10 03:07:18
【问题描述】:

我在 Visual Studio 2015 中有一个 .net 核心项目,我正在尝试部署到 AWS EB 环境,我收到大约 400 个关于无法解决依赖关系的错误,例如:project.json(19,66): error NU1001: The dependency EntityFramework.Core >= 7.0.0-rc1-final could not be resolved.

我也尝试从我的目录中运行 dotnet build 命令,但我得到了同样的错误,所以错误在我的项目中,而不是 AWS。

我认为这与我的 project.json 或我的项目中的某些配置有关,但我不知道是什么。

这是我的project.json 文件,如果有帮助的话:

{
  "version": "1.0.0-*",
  "webroot":  "wwwroot",
  "compilationOptions": {
    "emitEntryPoint": true
  },

  "dependencies": {
    "Microsoft.AspNet.Server.IIS": "1.0.0-beta7",
    "Microsoft.AspNet.IISPlatformHandler": "1.0.0-rc1-final",
    "Microsoft.AspNet.Server.Kestrel": "1.0.0-rc1-final",
    "Microsoft.AspNet.Mvc": "6.0.0-rc1-final",
    "Microsoft.AspNet.Mvc.ViewFeatures": "6.0.0-rc1-final",
    "Microsoft.AspNet.Mvc.TagHelpers": "6.0.0-rc1-final",
    "Microsoft.AspNet.StaticFiles": "1.0.0-rc1-final",
    "Microsoft.AspNet.Diagnostics": "1.0.0-rc1-final",
    "Microsoft.AspNet.Session": "1.0.0-rc1-final",
    "EntityFramework.MicrosoftSqlServer": "7.0.0-rc1-final",
    "EntityFramework.MicrosoftSqlServer.Design": "7.0.0-rc1-final",
    "EntityFramework.Commands": "7.0.0-rc1-final",
    "Microsoft.AspNet.Identity.EntityFramework": "3.0.0-rc1-final",
    "Microsoft.Framework.Configuration": "1.0.0-beta8",
    "Microsoft.Framework.ConfigurationModel": "1.0.0-beta4",
    "Microsoft.Framework.ConfigurationModel.UserSecrets": "1.0.0-beta4",
    "Microsoft.Framework.ConfigurationModel.Json": "1.0.0-beta4",
    "Microsoft.Extensions.Configuration.FileExtensions": "1.0.0-rc1-final",
    "Microsoft.Dnx.Runtime": "1.0.0-rc1-final",
    "MimeKit": "1.3.0-beta7",
    "MailKit": "1.3.0-beta7",
    "Google.Apis.Auth": "1.11.1"
  },

  "commands": {
    "web": "Microsoft.AspNet.Server.Kestrel",
    "ef": "EntityFramework.Commands"
  },

  "frameworks": {
    "dnx451": { }
  },

  "exclude": [
    "wwwroot",
    "node_modules",
    "bower_components"
  ],
  "publishExclude": [
    "**.user",
    "**.vspscc",
    "bower_components"
  ],
  "userSecretsId": "----"
}

项目确实运行,可以部署到本地目录,然后通过 ftp 上传到 iis 网络服务器,它可以正常工作。

有什么想法吗?

【问题讨论】:

    标签: amazon-web-services visual-studio-2015 dnx project.json .net-core


    【解决方案1】:

    我通过从我的包管理器控制台运行 dotnet restore 命令解决了这个问题

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2020-09-15
      • 2020-09-13
      • 1970-01-01
      • 1970-01-01
      • 2018-05-09
      • 2015-05-09
      • 2019-07-27
      相关资源
      最近更新 更多