<p>I create k8s cluster in aws by using kops</p>

<p>i wrote kubernetes cluster name : <code>test.fuzes.io</code></p>

<p>api url : <code>https://api.test.fuzes.io/api/v1</code></p>

<p>and i fill the CA Certificate field with result of </p>

<p><code>kubectl get secret {secrete_name} -o jsonpath="{['data']['ca\.crt']}" | base64 --decode</code></p>

<p>and finally i fill the Service Token field with result of</p>

<p><code>kubectl -n kube-system describe secret $(kubectl -n kube-system get secret | grep gitlab-admin | awk '{print $1}')</code></p>

<p>but when i save changes, i got message </p>

<p><code>There was a problem authenticating with your cluster. Please ensure your CA Certificate and Token are valid.</code></p>

<p>and i can't install helm tiller with kubernetes error:404</p>

<p>I really don't know what i did wrong. please help me....</p>

fuzes
<p>As @fuzes confirmed cluster re-creation can be a workaround for this issue. </p>

<p>This was also described on a GitLab Issues - <a href="https://gitlab.com/gitlab-org/gitlab-ee/issues/8897" rel="noreferrer">Kubernetes authentication not consistent</a></p>

<p>In short:
Using the same Kubernetes cluster integration configuration in multiple projects authenticates correctly on one but not the other.</p>

<p>Another suggestion to work around this by just setting <a href="https://docs.gitlab.com/ee/ci/variables/" rel="noreferrer">CI Variables</a> (<code>KUBE_NAMESPACE</code> and <code>KUBECONFIG</code>) instead of using our Kubernetes integration.</p>

<p>Hope this will be helpful for future references. </p>
