我正在嘗試安裝 Bitnami Mongodb。當我運行 ci/cd 管道時,出現以下錯誤:
錯誤:在 Chart.yaml 中找到,但在圖表/目錄中丟失:常見
這就是我的 gitlab-ci.yaml 檔案的樣子(包構建部分):
script:
- kubectl config set-context --current --namespace $NAMESPACE
- export HELM_EXPERIMENTAL_OCI=1 # nodig voor de repo add commands
- export HARBOR_ROBOT_SECRET_DECODED=$(echo -n "$HARBOR_ROBOT_SECRET" | base64 -d)
- helm registry login -u $HARBOR_ROBOT_NAME -p $HARBOR_ROBOT_SECRET_DECODED https://....../
- helm repo add --username $HARBOR_ROBOT_NAME --password $HARBOR_ROBOT_SECRET_DECODED --insecure-skip-tls-verify pgu https://..../chartrepo/pgu
- helm repo update
- helm dependency update
- helm repo add stable https://charts.helm.sh/stable
- helm repo add bitnami https://charts.bitnami.com/bitnami
- helm search repo bitnami
- >
helm upgrade --install -f values.yaml --set application.name=mongodb,application.registryServer=$REGISTRY_SERVER,application.image=namespace=$NAMESPACE $HELM_RELEASE_NAME $HELM_CHART --namespace=$NAMESPACE --version=$HELM_CHART_VERSION
我的 chart.yaml 檔案:
dependencies:
- name: common
repository: https://charts.bitnami.com/bitnami
tags:
- bitnami-common
更新:我運行除錯:
history.go:56: [debug] getting history for release mongodb
Release "mongodb" does not exist. Installing it now.
install.go:173: [debug] Original chart version: "1.0.0"
install.go:190: [debug] CHART PATH: /root/.cache/helm/repository/mongodb-v1.0.0.tgz
Error: found in Chart.yaml, but missing in charts/ directory: common
helm.go:88: [debug] found in Chart.yaml, but missing in charts/ directory: common
helm.sh/helm/v3/pkg/action.CheckDependencies
helm.sh/helm/v3/pkg/action/install.go:619
main.runInstall
helm.sh/helm/v3/cmd/helm/install.go:216
main.newUpgradeCmd.func2
helm.sh/helm/v3/cmd/helm/upgrade.go:115
github.com/spf13/cobra.(*Command).execute
github.com/spf13/cobra@v1.1.3/command.go:852
github.com/spf13/cobra.(*Command).ExecuteC
github.com/spf13/cobra@v1.1.3/command.go:960
github.com/spf13/cobra.(*Command).Execute
github.com/spf13/cobra@v1.1.3/command.go:897
main.main
helm.sh/helm/v3/cmd/helm/helm.go:87
runtime.main
runtime/proc.go:225
runtime.goexit
runtime/asm_amd64.s:1371
uj5u.com熱心網友回復:
已解決:替換原始圖表版本:“1.0.0”與包版本(相同)
install.go:173: [debug] 原始圖表版本:“11.0.6” install.go:190: [debug] CHART PATH: /root/.cache/helm/repository/mongodb-11.0.6.tgz
轉載請註明出處,本文鏈接:https://www.uj5u.com/qukuanlian/439789.html
標籤:mongodb github Kubernetes GitLab
