具有ASP.NET Core库的Docker容器 [英] Docker container with ASP.NET Core libraries

查看:171
本文介绍了具有ASP.NET Core库的Docker容器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

每次使用ASP.NET Core应用程序构建Dockerfile时,它都是来自网络Nuget存储的下载程序。



基本上我想用所有这些ASP .NET核心库(可能是我通常使用的一些库)。



从我的理解,我试图重塑GAC。



那么我的问题是可以使用像GAC这样的ASP.NET Core?或者,我的第二个想法是,将ASP.NET Core库下载到容器,然后以本地方式解析。



我的目标是为建立docker容器重新使用时间。 >

更新



看起来不可能

解决方案

现在有一个来自Microsoft的官方.NET Core Docker映像,包含所有需要的库。



得到它:



https: //hub.docker.com/r/microsoft/aspnetcore/



如果您需要自定义,请不要忘记您可以修改容器和使用docker commit创建自定义图像。


Each time I build Dockerfile with ASP.NET Core application it's download assemblies from web Nuget store.

Basically I'd like to create docker image with all this ASP.NET Core libraries (and probably some libraries I usually use).

From my understanding I trying to reinvent GAC.

So, my question is it possible to use something like GAC for ASP.NET Core? Or, my second thought, download ASP.NET Core libraries to container and then resolve it locally somehow.

My goal is to reduse time for building docker container.

UPDATE

Looks like it's impossible

解决方案

There is now an official .NET Core Docker image from Microsoft, with all the needed libraries.

You can get it here:

https://hub.docker.com/r/microsoft/aspnetcore/

If you need to customize it, don't forget you can modify the container and create a custom image with "docker commit".

这篇关于具有ASP.NET Core库的Docker容器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆