4

关于kaniko

 1 year ago
source link: https://www.bboy.app/2022/09/21/%E5%85%B3%E4%BA%8Ekaniko/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

关于kaniko

2022-09-21 13:30:00 kubernetes

20220921-1.webp

kaniko是一个不依赖于Docker守护进程,并且完全在用户空间中执行Dockerfile中的每个命令,用来编译镜像的工具。

https://github.com/GoogleContainerTools/kaniko

其实最主要记住下面三个参数就好了

--dockerfile 制定dockerfile路径 --context 定义上下文位置 --destination 远端镜像仓库

之后就是使用命令去构建

这个时候有意思的就来了,当推送到私有仓库的时候,官方文档上说

kaniko does not support the v1 Registry API (Registry v1 API Deprecation)

然后在创建 Docker credential 的时候,官方文档说

Note: Please use v1 endpoint. See #1209 for more details

然后这是1209

https://github.com/GoogleContainerTools/kaniko/issues/1209

然后我还是老老实实用docker in docker 吧

欢迎关注我的博客 www.bboy.app

Have Fun


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK