.angular 缓存文件夹应该添加到 .dockerignore 吗?
最近,通过Angular CLI创建了一个新文件夹'。到.gitignore文件。
我想知道,。
Recently updated a Angular project with the ng update
command from version 12 to version 13, at build time a new folder '.angular/cache' was created by Angular CLI, and in updates progress, adds this folder to the .gitignore file.
I want to know, Should the .angular cache folder add to .dockerignore? Is this action necessary or it is good practice?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
取决于您想要在 docker 镜像中包含什么。如果其目的是仅保留应用程序的构建版本,则您只需要 dist 文件夹中的任何内容。如果它的结果用于启动不同的 ng cli 命令,您可能希望为它们提供可用的缓存。
Depends on what do you want to have in your docker image. If its purpose is to only keep build version of your application you just need whatever was in dist folder. If its result is used to start different ng cli commands you may want to have cache available for them.