argoproj-labs / argocd-bot

Bot to automate Kubernetes deployment via Github PRs
Apache License 2.0
136 stars 21 forks source link

view_app_info.sh failed due to transport is closing #28

Open CH-anhngo opened 4 years ago

CH-anhngo commented 4 years ago

We tried to get the bot up and running. Even our webhook and subscribe events is correct but the bot didn't do anything. The argocd-bot pod has no logs. And if we mimic script ran it by hand it error out as below:

argocd@argocd-bot-6776676ffb-5n24f:~/argocd-bot$ argocd app list --plaintext
FATA[0000] rpc error: code = Unavailable desc = transport is closing
argocd@argocd-bot-6776676ffb-5n24f:~/argocd-bot$ argocd app get argo-events --plaintext
FATA[0000] rpc error: code = Unavailable desc = transport is closing 
mr-sour commented 4 years ago

Me again @CH-anhngo. Another thing I ran into while working on updates. I'm running the bot on EKS, and the AWS load balancer I was using didn't support http/2. I modified the scripts to include --grpc-web flag which allowed the cli to work. If you can get a shell in the pod try this and see if it works, I am running the bot in the same namespace as argocd but if your running it in its own namespace you can replace argocd-server with SVC_NAME.NAMESPACE_NAME If your running it on a separate cluster you'll need to make sure grpc ingress is working I found my normal way of setting up ingress didn't work because argocd runs grcp on the same port as tls.

argocd  --server argocd-server --auth-token AUTH_TOKEN app list --grpc-web --plaintext  --loglevel debug