Closed gaocegege closed 2 years ago
@gaocegege which sample are you referring to? There are PHP samples in the repo:
@gaocegege which guide/tutorial did you follow to run the sample? is it in Okteto Cloud? or in your own kubernetes cluster?
I use my own Kubernetes cluster. I first deploy the manifests via kubectl apply -f ./manifetsts/
. Then I run the command okteto up
. I got the error here.
x Application 'dev' not found in namespace 'default'
Verify that your application has been deployed and your Kubernetes context is pointing to the right namespace
Or set the 'autocreate' field in your okteto manifest if you want to create a standalone development container
More information is available here: https://okteto.com/docs/reference/cli/#up
After I added the field autocreate: true
in the okteto yaml, it works.
@gaocegege let me double-check two things:
okteto context show
is pointing to the same kubernetes context than kubectl
your okteto context show is pointing to the same kubernetes context than kubectl
Yes.
you okteto manifest has this content.
I am using this https://github.com/okteto/samples/blob/master/php/okteto.yml
@gaocegege you are right, I was looking to the wrong sample. yes, it should have autocreate: true
.
Would you mind creating a PR to add it?
I created a PR to fix it. PTAL
When I follow the guide to step 3, there is an error:
x Application 'dev' not found in namespace 'default' Verify that your application has been deployed and your Kubernetes context is pointing to the right namespace Or set the 'autocreate' field in your okteto manifest if you want to create a standalone development container More information is available here: https://okteto.com/docs/reference/cli/#up
We need to add
autocreate: true
in okteto.yaml