1. 환경
4vCore, 8GB 메모리, 20GB
2. SELINUX 비활성화
2. 1. SEINUX 설정에서 비활성화 설정
sed 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/selinux/config
2. 2. 현재 활성화된 SELINUX 비활성화
setenforce 0
3. firewalld 비활성화
3. 1. firewalld 서비스 종료
systemctl stop firewalld.service
3. 2. firewalld 부팅 시 자동으로 실행되지 않도록 설정
systemctl disable firewalld.service
4. 서버 리부팅
init 6
5. minikube 다운로드 및 설치
5. 1. minikube 다운로드
curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-latest.x86_64.rpm
5. 2. minikube 설치
rpm -Uvh minikube-latest.x86_64.rpm
6. docker 설치
6. 1. yum-utils 설치
yum install -y yum-utils
6. 2. docker 저장소 추가
yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
6. 3. docker 설치
yum install -y docker-ce docker-ce-cli containerd.io docker-compose-plugin
7. docker 구동
7. 1. docker 구동
systemctl start docker
7. 2. docker 부팅 시 자동으로 구동되도록 설정
systemctl enable docker
8. kubectl 설치
8. 1. kubectl 다운로드
curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl"
8. 2. kubectl 설치
install -o root -g root -m 0755 kubectl /usr/local/bin/kubectl
9. 루트가 아닌 계정(sudo 권한이 있는)에서 클러스터 사용하도록 설정
usermod -aG docker ioniere
10. minikube 구동
10. 1. 사용자 전환
su - ioniere
10. 2. minikube 구동
minikube start
10. 3. kubectl 연동
kubectl get po -A
10. 4. minikube dashboard 활성화
minikube addons enable dashboard
10. 5. minikube dashboard 백그라운드로 구동
nohup minikube dashboard 1> /dev/null 2>&1 &
10. 6. proxy를 이용하여 외부에서 접근되도록 설정
nohup kubectl proxy --address='0.0.0.0' --disable-filter=true 1> /dev/null 2>&1 &