System Engineering/Kubernetes
Kubernetes #4. 쿠버네티스 네트워크/Dashboard 설정하기
개요
Kubernetes클러스터에Dashboard설치
Dashboard for Kubernetes
kubernetes를 일반적인 유저가 커맨드라인이 아닌 가독성이 갖춰진 화면에서 작업을 하기위해선 쿠버네티스 Dashboard를 사용할 수 있다.
해당 포스팅은 아래의 글로부터 이어진다 :)
https://zunoxi.tistory.com/42?category=950191
1. Calico 설치 & Dashboard 설치
쿠버네티스의 클러스터 네트워킹 Plug-in 중 하나인Calico설치
curl -O https://docs.projectcalico.org/v3.9/manifests/calico.yaml
sed s/192.168.0.0\\/16/172.16.0.0\\/16/g -i calico.yaml
kubectl apply -f calico.yaml
Calico의 관련 pod의 status가 running중인지 확인 (시간이 꽤 소요된다. 여러번 계속 입력해서 확인)
kubectl get pods --all-namespaces
Dashboard 설치
kubectl apply -f https://raw.githubusercontent.com/kubetm/kubetm.github.io/master/sample/practice/appendix/gcp-kubernetes-dashboard.yaml
※ 20211014 기준, dashboard 설정 url이 변경되어 추가 포스팅합니다.
Dahsboard 설치
- 위 설치와 마찬가지로 로컬이나 https가 아닌 링크로도 접근이 되게끔하는 대시보드로 실제 운영환경에서 사용하기에는 부적절할 수 있습니다.
kubectl apply -f https://kubetm.github.io/documents/appendix/kubetm-dashboard-v1.10.1.yaml
2. Proxy 서버 띄우기
nohup kubectl proxy --port=8001 --address="본인 ip" --accept-hosts='^*$' >/dev/null 2>&1 &
- nohup을 사용하는 이유는백그라운드로 구동시키기 위함이다.
3. 접속 url 입력(브라우저의 주소창에)
http://”본인 ip”:8001/api/v1/namespaces/kube-system/services/https:kubernetes-dashboard:/proxy/
※ 추가 ++ 서버가 재기동되거나 프록시서버가 꺼져서 다시 dashboard를 띄워야 할때는
nohup kubectl proxy --port=8001 --address="본인 ip" --accept-hosts='^*$' >/dev/null 2>&1 &
요 작업만 다시 해주면 된다 😁
반응형
'System Engineering > Kubernetes' 카테고리의 다른 글
Kubernetes #6. Kubernetes의 Volume(쿠버네티스 볼륨) (0) | 2020.07.20 |
---|---|
Kubernetes #5. Kubernetes의 Pod와 Service(쿠버네티스 파드와 서비스) (0) | 2020.05.30 |
Kubernetes #3. 쿠버네티스 Unable to connect to the server: x509 에러 (0) | 2020.04.27 |
Kubernetes #2. CentOS7에 쿠버네티스 설치하기 (0) | 2020.04.27 |
Kubernetes #1. 쿠버네티스(Kubernetes)란 / 쿠버네티스의 기능 (0) | 2020.04.02 |
댓글