Closed ashish-gupta-2 closed 2 years ago
Any more info than this?
YAML file :
resource_types:
- name: helm
type: docker-image
source:
repository: typositoire/concourse-helm3-resource
tag: v1.23.0
resources:
- name: test-helm
type: helm
source:
cluster_url: <>
token:<>
namespace: <>
insecure_cluster: true
stable_repo: true
jobs:
- name: test-deploy
plan:
- get: <resource>
trigger: true
- put: test-helm
params:
uninstall: test-release --ignore-not-found=true
wait: 300
- put: test-helm
params:
chart: <path of chart>
release: test-release
values: <path of value file>
wait: 300
concourse version: v7.5.0
Hope this will help!
Just making sure, cluster_url
has http
or https
at the start and <>
are redacted values?
Oh wait I've just seen: stable_repo: true
. Pretty sure this doesn't work anymore, if you remove this line does it work?
Also can you enable tracing? .source.tracing_enabled
to true.
yes the cluster_url has https at the start
and the actual values are replaced with <> this
and when I removed this
stable_repo: true
then getting below issue :
Are you sure? This is what I would expect from having it... not removing it :/ Can you also try with .source.tracing_enabled: true
in the resource definition?
Yes , i am sure ,
Please find the log traces :
selected worker: 6e80a0e3623f
++ jq -r '.source.digitalocean // "false"'
+ digitalocean=false
++ jq -r '.source.digitalocean.cluster_id // "false"'
+ do_cluster_id=false
++ jq -r '.source.digitalocean.access_token // "false"'
+ do_access_token=false
++ jq -r '.source.gcloud_cluster_auth // "false"'
+ gcloud_cluster_auth=false
+ '[' false '!=' false ']'
+ '[' false = true ']'
+ echo 'Initializing kubectl using certificates'
Initializing kubectl using certificates
+ setup_kubernetes helm-resource-request.GHDAHP /tmp/build/put
+ payload=helm-resource-request.GHDAHP
+ source=/tmp/build/put
+ mkdir -p /root/.kube
++ jq -r '.params.kubeconfig_path // ""'
+ kubeconfig_path=
+ absolute_kubeconfig_path=/tmp/build/put/
++ jq -r '.params.kubeconfig // ""'
+ kubeconfig=
+ '[' '!' -z '' ']'
+ '[' -f /tmp/build/put/ ']'
++ jq -r '.source.cluster_url // ""'
+ cluster_url=<remove the actual string>
+ '[' -z <remove the actual string> ']'
+ [[ <remove the actual string> =~ https.* ]]
++ jq -r '.source.insecure_cluster // "false"'
+ insecure_cluster=true
++ jq -r '.source.cluster_ca // ""'
+ cluster_ca=
++ jq -r '.source.admin_key // ""'
+ admin_key=
++ jq -r '.source.admin_cert // ""'
+ admin_cert=
++ jq -r '.source.token // ""'
+ token=<remove the actual token string>
++ jq -r '.params.token_path // ""'
+ token_path=
+ '[' true == true ']'
+ kubectl config set-cluster default --server=<remove the actual string> --insecure-skip-tls-verify=true
Cluster "default" set.
+ '[' -f /tmp/build/put/ ']'
+ '[' '!' -z <remove the actual token string> ']'
+ kubectl config set-credentials admin --token=<remove the actual token string>
User "admin" set.
+ kubectl config set-context default --cluster=default --user=admin
Context "default" created.
+ kubectl config use-context default
Switched to context "default".
+ kubectl version
Client Version: version.Info{Major:"1", Minor:"21", GitVersion:"v1.21.5", GitCommit:"<removed commit id>", GitTreeState:"clean", BuildDate:"2021-09-15T21:10:45Z", GoVersion:"go1.16.8", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"21", GitVersion:"v1.21.3+k3s1", GitCommit:"<removed commit id>", GitTreeState:"clean", BuildDate:"2021-07-22T20:52:14Z", GoVersion:"go1.16.6", Compiler:"gc", Platform:"linux/amd64"}
+ echo 'Initializing helm...'
Initializing helm...
+ setup_helm helm-resource-request.GHDAHP /tmp/build/put
++ jq -r '.source.helm_history_max // "0"'
+ history_max=0
+ helm_bin=helm
+ helm version
version.BuildInfo{Version:"v3.8.0", GitCommit:"d14138609b01886f544b2025f5000351c9eb092e", GitTreeState:"clean", GoVersion:"go1.17.5"}
++ jq -r '.source.helm_setup_purge_all // "false"'
+ helm_setup_purge_all=false
+ '[' false = true ']'
+ setup_repos helm-resource-request.GHDAHP /tmp/build/put
++ jq -c '(try .source.repos[] catch [][])'
+ repos=
++ jq -c '(try .source.plugins[] catch [][])'
+ plugins=
++ jq -r '.source.stable_repo // "https://charts.helm.sh/stable"'
+ stable_repo=https://charts.helm.sh/stable
+ local 'IFS=
'
+ '[' '' ']'
+ '[' '' ']'
+ '[' '!' https://charts.helm.sh/stable == false ']'
+ helm repo add stable https://charts.helm.sh/stable
Error: looks like "https://charts.helm.sh/stable" is not a valid chart repository or cannot be reached: Get "https://charts.helm.sh/stable/index.yaml": x509: certificate signed by unknown authority
I'm sorry but I can't reproduce the error you're getting. Is your concourse using some kind of proxy to reach the internet?
Initializing helm... version.BuildInfo{Version:"v3.8.0", GitCommit:"d14138609b01886f544b2025f5000351c9eb092e", GitTreeState:"clean", GoVersion:"go1.17.5"} Error: could not find protocol handler for: