joshmeranda / chartsutil

MIT License
0 stars 0 forks source link

SSL related issue when pulling repo on arm64+darwin #1

Open mallardduck opened 1 week ago

mallardduck commented 1 week ago

Here is the command I'm running:

PACKAGE=rancher-monitoring/rancher-monitoring ./bin/chartsutil rebase 35bcf70c8a6f6ecb7f996021f4c1dabc736d0138

And the error (well all the output really) I'm getting:

time=2024-11-01T00:02:02.386-04:00 level=INFO msg="attempting to rebase pacakge" pkg=rancher-monitoring/rancher-monitoring from=https://github.com/prometheus-community/helm-charts.git@2ee818aaae56fd93d27652e6d878e15140636aaf/charts/kube-prometheus-stack to=https://github.com/prometheus-community/helm-charts.git@2ee818aaae56fd93d27652e6d878e15140636aaf/charts/kube-prometheus-stack incremental=false
time=2024-11-01T00:02:08.411-04:00 level=INFO msg="preparing package"
Error: failed to prepare the chart: encountered error while preparing main chart: encountered error while trying to pull upstream into charts: Get "https://github.com/prometheus-community/helm-charts.git/info/refs?service=git-upload-pack": tls: failed to verify certificate: SecPolicyCreateSSL error: 0

Second weird thing is that after the failure the ./bin dir is nuked. See:

± |util-test {2} ✓| → make pull-scripts
./scripts/pull-scripts
Downloading charts-build-scripts version https://github.com/rancher/charts-build-scripts.git@v1.0.0
charts-build-scripts_darwin_arm64 => ./bin/charts-build-scripts
charts-build-scripts version 1.0.0 (d59848e)

± |util-test {2} ?:1 ✗| → ls ./bin/
charts-build-scripts

± |util-test {2} ✓| → curl https://raw.githubusercontent.com/joshmeranda/chartsutil/main/hack/install.sh | bash
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  1063  100  1063    0     0  25184      0 --:--:-- --:--:-- --:--:-- 25309
CHARTS_BUILD_SCRIPT_VERSION is not set, checking 'scripts/version'
Using charts-build-script version v1.0.0
Installing chartsutils into /Users/danpock/GitProjects/SUSE/rancher-charts/bin

± |util-test {2} ?:1 ✗| → ls ./bin/
charts-build-scripts chartsutil

Then I run the command above, and see:

[command]
Error: failed to prepare the chart: encountered error while preparing main chart: encountered error while trying to pull upstream into charts: Get "https://github.com/prometheus-community/helm-charts.git/info/refs?service=git-upload-pack": tls: failed to verify certificate: SecPolicyCreateSSL error: 0

± |util-test {2} ✓| → ls bin
ls: bin: No such file or directory
mallardduck commented 1 week ago

Hmm. So I'll help look into this issue further another time. I was able to get the binary working by cloning the repo and building it manually. Then I'm just running it from inside my charts repo calling it from the path it built at.

Now I can focus on learning the actual process and starting the rebase, but will still comeback to this.