kubernetes 맛보기-6. namespace

mhlee·2021년 6월 7일
0

1. namespace 생성

namespace는 아래와 같이 아주 간단하게 생성할수 있다.

kubectl create ns office

2. namespace 사용

office 란 namespace에 mynginx deploy를 생성한다.
그리고, get pod을 하면 조회되지 않는것을 확인할수 있다.
왜냐하면, office라는 namespace 생성되었기 때문이다.
-n office를 추가하고 조회하면 정상적으로 조회됨을 확인할수 있다.

kubectl create deploy mynginx --image nginx -n office
kubectl get pod -n office

profile
삽질하는 개발자

0개의 댓글