create namespace
kubectl create namespace test-team
vi moon.yml
*******************************************
apiVersion: v1
kind: Pod
metadata:
name: pod1
namespace: test-team
labels:
tier: frontend
spec:
containers:
- name: podngin
image: nginx
0r
kubectl apply -f moon.yml -n test-team
kubectl get pods -n test-team
**************************************************
kubectl delete
kubectl delete pod pod1 -n test-team
how to change default NameSpace ?
kubectl config set-context --current --namespace=test-team
No comments:
Post a Comment