none
Data Points - EF Core in a Docker Containerized App, Part 2 RRS feed

  • General discussion

  • In the second in a series on using EF Core and Docker together to build a containerized app and add a data persistence mechanism, Julie Lerman looks at production-worthy solutions for targeting SQL Server when publishing an API inside of a Docker image.

    Read this article in the May 2019 issue of MSDN Magazine

    Wednesday, May 1, 2019 5:19 PM
    Owner

All replies

  • Just a comment on this:

    >When I used the tooling to add the container orchestration, the .dockerignore file that the tooling created lists .env files, so those won’t get accidentally pushed to your source control.

    .dockerignore has nothing to do with source control. This file tells docker what files to ignore when it creates the context for the docker build command. https://docs.docker.com/engine/reference/builder/

    You would still need to add .env to your .gitignore or whatever ignore your scc uses.

    Tuesday, July 9, 2019 2:45 PM
  • Thanks Bob! I appreciate the clarification not only for my own knowledge but to help other readers!

    Julie Lerman, Author of Programming Entity Framework, MVP

    Wednesday, July 10, 2019 1:02 AM
    Answerer
  • Hi Julie.

    In the Dockerfile, ConnectionStrings:MagsConnectionMssql did not work for me.

    I had to use ConnectionStrings__MagsConnectionMssql. This usage is documented here

    6 hours 18 minutes ago