Why use Docker for .NET web apps when we have WebDeploy?

后端 未结 1 1598
小蘑菇
小蘑菇 2021-02-20 14:08

In the Microsoft ecosystem, people were happily deploying web apps using WebDeploy Packages until Docker came along. Suddenly everyone started preferring to use Docker instead,

相关标签:
1条回答
  • 2021-02-20 14:38

    One of docker feature is to record an execution environment in an archive called an image.

    That way, you don't have to setup the exact same configuration on a new machine, you can simply run said image on any machine supporting docker, and presumably get the exact same environment execution (same Windows, same Webdeploy version, same IIS, ...)

    A WebDeploy Packages is a deployment artifact (like a jar, war, or any other artifacts), which does not include what is needed to run said artifact.

    A docker image includes everything already installed, ready to be executed.
    You can have the same image used at runtime (docker run) with:

    • different configuration files (through bind mounts or volumes)
    • different environment variable (docker run -e var=value)
    0 讨论(0)
提交回复
热议问题