dotnet ef not found in .NET Core 3

后端 未结 8 1824
囚心锁ツ
囚心锁ツ 2020-12-02 04:35

I\'m following the docs in order to create an initial migration. When I execute dotnet, I get the help section, meaning that the PATH works properly.

Th

相关标签:
8条回答
  • 2020-12-02 05:12

    I had the same problem. I resolved, uninstalling all de the versions in my pc and then reinstall dotnet.

    0 讨论(0)
  • 2020-12-02 05:19

    EDIT: If you are using a Dockerfile for deployments these are the steps you need to take to resolve this issue.

    Change your Dockerfile to include the following:

    FROM mcr.microsoft.com/dotnet/core/sdk:3.1 AS build-env
    ENV PATH $PATH:/root/.dotnet/tools
    RUN dotnet tool install -g dotnet-ef --version 3.1.1
    

    Also change your dotnet ef commands to be dotnet-ef

    0 讨论(0)
提交回复
热议问题