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

🐞 反馈问题:helm配置内网https镜像仓库安装rainbond后,页面提示数据中心操作故障 #2152

Open
3 of 4 tasks
KeKouShi opened this issue Feb 19, 2025 · 11 comments
Assignees
Labels
Bug BUG Feedback

Comments

@KeKouShi
Copy link

请先确认以下事项:

问题描述

  1. helm安装rainbond,所配置为内网https镜像仓库,安装完成后,页面提示
    数据中心操作故障 {'apitype': 'Not specified', 'url': 'https://rbd-api-api:8443/v2/tenants/default/image-repositories?namespace=default', 'method': 'GET', 'httpcode': 503, 'body': {'error': '部分服务不可用'}}
  2. rbd-chaos组件报错
    level=error msg="create hub client failed, try time is 10,registry url http:

该问题是否可以稳定重现?

可重现

重现步骤

rainbond镜像上传https镜像仓库
配置外部镜像仓库安装rainbond

截图

Image

Image

日志

level=error msg="create hub client failed, try time is 10,registry url http://idt.ccwork.com:8076: Get "http://*******/v2/": http: non-successful response (status=400 body="\r\n<title>400 The plain HTTP request was sent to HTTPS port</title>\r\n\r\n

400 Bad Request

\r\nThe plain HTTP request was sent to HTTPS port\r\n
nginx\r\n\r\n\r\n")"

期望结果

可以正常添加组件

解决方案(可选)

No response

操作系统 && Rainbond 版本

openEuler 22.03 k3s v6.1.1-release

是否愿意提交 PR 解决该问题?

  • 我愿意提交 PR 来解决该问题
@KeKouShi KeKouShi added the Bug BUG Feedback label Feb 19, 2025
@Issues-translate-bot
Copy link

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


Title: 🐞 Feedback problem: After helm configures the intranet https mirror warehouse to install rainbond, the page prompts data center operation failure

@zzzhangqi
Copy link
Collaborator

@KeKouShi domain 字段不需要携带 https http 等协议

@Issues-translate-bot
Copy link

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


@KeKouShi domain field does not need to carry protocols such as https http

@KeKouShi
Copy link
Author

@zzzhangqi domain 字段不带https或http也是相同的报错

@Issues-translate-bot
Copy link

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


@zzzhangqi domain field does not contain https or http, and the same error is reported.

@zzzhangqi
Copy link
Collaborator

@KeKouShi 你的镜像仓库协议是 http 还是 https,仓库类型是 harbor 还是 docker registry

@Issues-translate-bot
Copy link

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


@KeKouShi Is your image repository protocol http or https, is the repository type harbor or docker registry

@KeKouShi
Copy link
Author

@zzzhangqi 镜像仓库协议是https,类型是harbor,使用helm安装时,就是从此仓库拉取的镜像

@Issues-translate-bot
Copy link

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


@zzzhangqi The mirror repository protocol is https, the type is harbor. When installed using helm, it is the mirror pulled from this repository.

@zzzhangqi
Copy link
Collaborator

@KeKouShi 未复现问题。

我搭建了 Docker Registry 并自签发了私有证书,用 K3s 搭建的单机测试环境。如下:

  1. 使用 Docker Registry 搭建本地私有镜像仓库
docker run -v /root/cert:/cert \
-e REGISTRY_HTTP_TLS_CERTIFICATE=/cert/cert.crt \
-e REGISTRY_HTTP_TLS_KEY=/cert/cert.key \
-p 5000:5000 \
-d registry:2.8
  1. K3s 私有镜像仓库配置文件
$ cat /etc/rancher/k3s/registries.yaml

configs:
  "10.64.0.7:5000":
    auth:
      username: admin
      password: admin1234
    tls:
      insecure_skip_verify: true
  1. Rainbond values.yaml 配置文件
$ cat values.yaml 
Cluster:
  gatewayIngressIPs: 10.64.0.7

  nodesForGateway:
  - externalIP: 10.64.0.7
    internalIP: 10.64.0.7
    name: iv-ydq6bajda8k36d19ye26
  nodesForChaos:
  - name: iv-ydq6bajda8k36d19ye26
  containerdRuntimePath: /var/run/k3s/containerd

  imageHub:
    enable: true
    domain: 10.64.0.7:5000
    namespace: rainbond
    username: admin
    password: admin
  1. Rainbond Pod
$ kubectl get pod -n rbd-system
NAME                                      READY   STATUS    RESTARTS   AGE
local-path-provisioner-5476dcfbb8-wj6w5   1/1     Running   0          9m44s
minio-0                                   1/1     Running   0          9m47s
rainbond-operator-9b5876fcb-djg84         1/1     Running   0          9m50s
rbd-api-5bb68877f4-pw22s                  1/1     Running   0          9m29s
rbd-app-ui-587dd78fc4-2r66h               1/1     Running   0          8m42s
rbd-chaos-hk7fp                           1/1     Running   0          9m24s
rbd-db-0                                  1/1     Running   0          9m46s
rbd-gateway-7877b5f969-c8926              2/2     Running   0          9m43s
rbd-monitor-0                             1/1     Running   0          9m46s
rbd-mq-545d6748f5-v9zfq                   1/1     Running   0          9m46s
rbd-worker-6bdd5f86-9wsqg                 1/1     Running   0          9m41s
  1. Rainbond 源码构建截图
    Image

@Issues-translate-bot
Copy link

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


@KeKouShi The problem was not reproduced.

I built Docker Registry and issued a private certificate to a stand-alone test environment built with K3s. as follows:

  1. Use Docker Registry to build a local private image repository
docker run -v /root/cert:/cert \
-e REGISTRY_HTTP_TLS_CERTIFICATE=/cert/cert.crt \
-e REGISTRY_HTTP_TLS_KEY=/cert/cert.key \
-p 5000:5000 \
-d registry:2.8
  1. K3s private mirror repository configuration file
$ cat /etc/rancher/k3s/registries.yaml

configs:
  "10.64.0.7:5000":
    auth:
      username: admin
      password: admin1234
    tls:
      insecure_skip_verify: true
  1. Rainbond values.yaml configuration file
$ cat values.yaml
Cluster:
  gatewayIngressIPs: 10.64.0.7

  nodesForGateway:
  - externalIP: 10.64.0.7
    internalIP: 10.64.0.7
    name: iv-ydq6bajda8k36d19ye26
  nodesForChaos:
  - name: iv-ydq6bajda8k36d19ye26
  containerdRuntimePath: /var/run/k3s/containerd

  imageHub:
    enable: true
    domain: 10.64.0.7:5000
    namespace: rainbond
    username: admin
    password: admin
  1. Rainbond Pod
$ kubectl get pod -n rbd-system
NAME READY STATUS RESTARTS AGE
local-path-provisioner-5476dcfbb8-wj6w5 1/1 Running 0 9m44s
minio-0 1/1 Running 0 9m47s
rainbond-operator-9b5876fcb-djg84 1/1 Running 0 9m50s
rbd-api-5bb68877f4-pw22s 1/1 Running 0 9m29s
rbd-app-ui-587dd78fc4-2r66h 1/1 Running 0 8m42s
rbd-chaos-hk7fp 1/1 Running 0 9m24s
rbd-db-0 1/1 Running 0 9m46s
rbd-gateway-7877b5f969-c8926 2/2 Running 0 9m43s
rbd-monitor-0 1/1 Running 0 9m46s
rbd-mq-545d6748f5-v9zfq 1/1 Running 0 9m46s
rbd-worker-6bdd5f86-9wsqg 1/1 Running 0 9m41s
  1. Rainbond source code construction screenshot
    Image

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

No branches or pull requests

3 participants