Skip to content

Unable to add K3s cluster #6135

Closed
Closed

Description

@vvijayv

If you are trying to resolve an environment-specific issue or have a one-off question about the edge case that does not require a feature then please consider asking a question in argocd slack channel.

Checklist:

  • I've searched in the docs and FAQ for my answer: https://bit.ly/argocd-faq.
  • I've included steps to reproduce the bug.
  • I've pasted the output of argocd version.

Describe the bug
I have 2 K3s in my Mac, one has the Argocd. Now, when I connect to another K3s cluster using argocd cluster add <context-name> I get the below error

INFO[0000] ServiceAccount "argocd-manager" already exists in namespace "kube-system"
INFO[0000] ClusterRole "argocd-manager-role" updated
INFO[0000] ClusterRoleBinding "argocd-manager-role-binding" updated
FATA[0001] Failed to establish connection to localhost:8080: dial tcp [::1]:8080: connect: connection refused

To Reproduce

  1. create 2 k3s clusters (using k3sup or k3d)
  2. Install argocd in one of the cluster following the step described in the argocd doc
  3. run argocd cluster add <2nd-cluster-context-name>

Expected behavior
It should add the 2nd cluster?

Version

argocd: v2.0.1+33eaf11.dirty
BuildDate: 2021-04-21T18:44:13Z
GitCommit: 33eaf11
GitTreeState: dirty
GoVersion: go1.16.3
Compiler: gc
Platform: darwin/amd64
argocd-server: v2.0.0+f5119c0
BuildDate: 2021-04-07T06:00:33Z
GitCommit: f5119c0
GitTreeState: clean
GoVersion: go1.16
Compiler: gc
Platform: linux/amd64
Ksonnet Version: v0.13.1
Kustomize Version: v3.9.4 2021-02-09T19:22:10Z
Helm Version: v3.5.1+g32c2223
Kubectl Version: v0.20.4
Jsonnet Version: v0.17.0

INFO[0000] ServiceAccount "argocd-manager" already exists in namespace "kube-system"
INFO[0000] ClusterRole "argocd-manager-role" updated
INFO[0000] ClusterRoleBinding "argocd-manager-role-binding" updated
FATA[0001] Failed to establish connection to localhost:8080: dial tcp [::1]:8080: connect: connection refused

Activity

  1. jannfis commented on May 1, 2021

    @jannfis
    Member

    You need to setup the context in your ~/.kube/config so that it points to an URL of the K8s control plane's API reachable by the cluster Argo CD is running in. Yours is setup to connect to localhost, as indicated by

    FATA[0001] Failed to establish connection to localhost:8080: dial tcp [::1]:8080: connect: connection refused
    

    You may also have to reconfigure your k3s to make this work. This is not an Argo CD bug.

  2. locked and limited conversation to collaborators on May 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions