Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

调整 Kaniko 构建参数异常 #1778

Closed
anhao opened this issue Nov 6, 2023 · 5 comments
Closed

调整 Kaniko 构建参数异常 #1778

anhao opened this issue Nov 6, 2023 · 5 comments
Assignees
Labels
kind/bug BUG Feedback

Comments

@anhao
Copy link

anhao commented Nov 6, 2023

调整 kaniko 镜像加速 后 chaos 提示 unknown flag: --kaniko-args

To Reproduce

Screenshots
image

image

The relevant information:
v5.15.2-release-ff32a0912-2023-09-10-15

@anhao anhao added the kind/bug BUG Feedback label Nov 6, 2023
@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Title: Adjust Kaniko build parameter exception

@yangkaa
Copy link
Collaborator

yangkaa commented Nov 6, 2023

在 5.15.2 版本中,已经弃用了 kaniko 构建,使用 buildkit 构建。如果你需要配置镜像加速。可以参考以下步骤:

  1. 找到镜像仓库的配置文件,通常在 rbd-system 命名空间下,如果你使用的内置镜像仓库,应该是一个 goodrain-me 的 configmap。如果你更换了外部镜像仓库,应该是外部镜像仓库的域名,中间以“-”分割。
kubectl get cm -nrbd-system
  1. 编辑这个 Configmap
kubectl edit cm goodrain-me -nrbd-system
  1. 修改为如下配置,其中 mirrors 是镜像加速的地址
apiVersion: v1
data:
  buildkittoml: |-
    debug = true
    [registry."goodrain.me"]
      http = false
      insecure = true
    [registry."docker.io"]
      mirrors = ["192.168.18.145"]
kind: ConfigMap
metadata:
  name: goodrain.me
  namespace: rbd-system

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


In version 5.15.2, kaniko builds have been deprecated in favor of buildkit builds. If you need to configure image acceleration. You can refer to the following steps:

  1. Find the configuration file of the image repository, usually under the rbd-system namespace. If you use the built-in image repository, it should be a goodrain-me configmap. If you have changed the external mirror warehouse, it should be the domain name of the external mirror warehouse, separated by "-" in the middle.
kubectl get cm -nrbd-system
  1. Edit this Configmap
kubectl edit cm goodrain-me -nrbd-system
  1. Modify to the following configuration, where mirrors is the address of mirror acceleration
apiVersion: v1
data:
  buildkittoml: |-
    debug=true
    [registry."goodrain.me"]
      http = false
      insecure=true
    [registry."docker.io"]
      mirrors = ["192.168.18.145"]
kind: ConfigMap
metadata:
  name: goodrain.me
  namespace: rbd-system

@ZhangSetSail
Copy link
Collaborator

如果没有其他问题,该issues将在明天关闭

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


If there are no other issues, the issues will be closed tomorrow

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug BUG Feedback
Projects
None yet
Development

No branches or pull requests

4 participants