<p>I have a problem with Google cloud console and kubernates</p>
<p>i have two projects:</p>
<pre><code>$ gcloud projects list
PROJECT_ID      NAME           PROJECT_NUMBER
telemetry       Telemetry      571056202575
opex-prod       OPEX           992345650242
</code></pre>
<p>If I check current project:</p>
<pre><code>$ gcloud config get-value project
Your active configuration is: [cloudshell-20766]
telemetry
</code></pre>
<p>and list of my namespaces (i will show only my namespace, not default and kube* ones):</p>
<pre><code>$ kubectl get namespace
NAME              STATUS   AGE
development       Active   3d18h
</code></pre>
<p>so, now if I want change project (which has different pods and namespaces):</p>
<pre><code>$ gcloud config set project opex-prod
Updated property [core/project].
$ gcloud config get-value project
Your active configuration is: [cloudshell-20766]
opex-prod
</code></pre>
<p>but if i check the namespaces on opex-prox project i will have namespace of my other project</p>
<pre><code>$ kubectl get namespace
NAME              STATUS   AGE
development       Active   3d18h
</code></pre>
<p>in <code>opex-prod</code> I don't have <code>development</code> but <code>prod-a</code></p>
<p>If i change projects and namespaces in Google Cloud dashboard I can see correct namespaces</p>
<p>what i'm missing??</p>

Ging3r
<p>kubectl commands don't work based on gcloud project config. They work based on kubeconfig set in your local environment. To set kubeconfig to point to a particular project's cluster, run <code>gcloud container clusters get-credentials cluster-name</code> command after you change your gcloud project config. Read <a href="https://cloud.google.com/kubernetes-engine/docs/how-to/cluster-access-for-kubectl" rel="nofollow noreferrer">here</a> for more info.</p>
