Lab 8 – gitlab autodevops

hello ,

In latest LAB8 GITLAB AUTODEVOPS :slight_smile:

I meet this problème even if i added th CA.CRT file when i added agentk to the cluster :
“”“”“”
helm repo add gitlab https://charts.gitlab.io
helm repo update
helm upgrade --install kk-agent gitlab/gitlab-agent
–namespace gitlab-agent-kk-agent
–create-namespace
–set image.tag=v16.9.0-rc1
–set config.token=
–set-file config.caCert=/etc/gitlab/ssl/ca.crt
–set config.kasAddress=wss://gitlab.kodekloud.com/-/kubernetes-agent/
“”“”“”"
{“level”:“error”,“time”:“2024-05-21T07:56:09.084Z”,“msg”:“Failed to register agent pod. Please make sure the agent version matches the server version”,“mod_name”:“agent_registrar”,“error”:“rpc error: code = Unavailable desc = connection error: desc = "transport: Error while dialing: failed to WebSocket dial: failed to send handshake request: Get \"https://gitlab.kodekloud.com/-/kubernetes-agent/\\\”: tls: failed to verify certificate: x509: certificate signed by unknown authority""}

Hello Bouchta,

from you’re error I think you’re working with a self-signed certificate in you gitlab server, so you need to authorise that certificate in the agent you trying to install and to do that you just need to add this to your helm command:
--set-file config.kasCaCert=your-cert.crt

yes is working now , thanks