<p>I have a Gitlab runner using a K8s executor. But when running the pipeline I am getting below error</p>

<pre><code>Checking for jobs... received                       job=552009999 
repo_url=https://gitlab.com/deadbug/rns.git runner=ZuT1t3BJ
WARNING: Namespace is empty, therefore assuming 'default'.  job=552009999 project=18763260 
runner=ThT1t3BJ
ERROR: Job failed (system failure): secrets is forbidden: User "deadbug" cannot create resource 
"secrets" in API group "" in the namespace "default"  duration=548.0062ms job=552009999 
</code></pre>

<p>From the error message, I undestand the namespace needs to be updated. I specified namespace in the Gitlab variables</p>

<p><a href="https://i.stack.imgur.com/VCRua.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/VCRua.png" alt="enter image description here"></a></p>

<p>But after this also, pipeline is failing with the above error message. How do I change the namespace for the runner ?</p>

deadbug
<p>This seems to be linked to the permissions of the service account rather than the namespace directly. If you use GitLab's Kubernetes integration, you should not override the namespace, as GitLab will create one for you.</p>

<p>Make sure the service account you added to GitLab has the correct role. From <a href="https://docs.gitlab.com/ee/user/project/clusters/add_remove_clusters.html" rel="nofollow noreferrer">https://docs.gitlab.com/ee/user/project/clusters/add_remove_clusters.html</a>:</p>

<blockquote>
  <p>When GitLab creates the cluster, a gitlab service account with cluster-admin privileges is created in the default namespace to manage the newly created cluster</p>
</blockquote>
