KEMBAR78
Minikube Setup On Centos 8 - Nginx - Setup | PDF | Software Repository | Information Technology
0% found this document useful (0 votes)
20 views4 pages

Minikube Setup On Centos 8 - Nginx - Setup

Uploaded by

srinu katams
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
20 views4 pages

Minikube Setup On Centos 8 - Nginx - Setup

Uploaded by

srinu katams
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 4

For Minikube Setup on Centos 8:

Pre requisits

1. Docker

2. Kubernet components

3. Go binaries

4. CRI docker

5. Terraform

In this tutorial, we will learn How to install Minikube on CentOS 7 and 8. Minikube
is free software that lets you set up a small Kubernetes cluster with a single
computer. The software starts up a virtual machine and runs a Kubernetes cluster
inside of it. This lets you test directly in a Kubernetes environment.

Prerequisites
A normal user with SUDO privileges or Super user
Yum repositories configured to install packages in your CentOS server.
Steps to install Minikube on Centos
Step 1: Update your machine

yum -y update
Step 2: Install EPEL repositories using below command.

yum -y install epel-release


Step 3: Install libvirt packages, dependencies to run Minikube

yum -y install libvirt qemu-kvm virt-install virt-top libguestfs-tools bridge-utils


Step 4: Now run, enable and check the status of libvirt daemon to ensure it is
running and installed successfully.

systemctl enable --now libvirtd


systemctl status libvirtd
Step 5: Now, add your any normal user to libvirt group by using usermod command.

usermod -a -G libvirt <normal-username>


usermod -a -G libvirt prabhu # my normal user
Step 6: Now, append the below mentioned details to the below file.

vi /etc/libvirt/libvirtd.conf
Append contend to above file::

unix_sock_group = "libvirt"

unix_sock_rw_perms = "0770"

Step 7: Restart the libvirtd daemon/ service to reflcet the changes.

systemctl restart libvirtd.service


Download Minikube binary
Step 8: Download and install the minikube binary using the curl and install command
as shown below.
curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-linux-
amd64
sudo install minikube-linux-amd64 /usr/local/bin/minikube
Step 9: Check the version installed of your minikube.

minikube version
Minikube install on CentOS
Minikube install on CentOS
Download Kubectl binary and installed it
Step 10: Download the latest kubectl binary using the below command

curl -LO https://storage.googleapis.com/kubernetes-release/release/`curl -s


https://storage.googleapis.com/kubernetes-release/release/stable.txt`/bin/linux/
amd64/kubectl
Step 11: Now, make the binary executable, so the it can be run

chmod +x kubectl
Step 12: Move the binary to /usr/loca/bin directory so that it can be run from
anywhere of your machine.

mv kubectl /usr/local/bin
Step 13: Check the version installed on your centos machine

kubectl version --client -o json

Version of installed kubectl


Install Docker container
Step 14: Now, without, docker environment, you cannot run minikube. Therefore, run
the below command to add the repolist to your machine to install Docker.

yum install -y yum-utils


yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-
ce.repo
Step 15: Install the docker related dependencies to run your minikube.

yum install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-


compose-plugin
Step 16: Now, run the below command to enable and start the docker service
instantly

systemctl enable --now docker


Step 17: Check the docker running version.

docker version
Docker installed on Centos
Docker installed on Centos
Step 18: Now, add your normal user( user which is added to libvirt group in earlier
step) to the docker group as well.

usermod -aG docker prabhu


Step 19: Now, switch to that user and run the minikube with driver docker as a
default driver.

su - prabhu
minikube start --driver=docker
Minikube installed and running on centos
Minikube installed and running on centos
And, that's how, you have learnt how to install Minikube on CentOS 7 and 8.
==============

1 11/01/24 05:19:55 yum -y update


2 11/01/24 05:20:10 sudo yum update
3 11/01/24 05:28:25 sudo yum -y install epel-release
4 11/01/24 05:28:38 sudo yum -y install libvirt qemu-kvm virt-install virt-top
libguestfs-tools bridge-utils
5 11/01/24 05:30:44 sudo systemctl enable --now libvirtd
6 11/01/24 05:30:57 sudo systemctl status libvirtd
7 11/01/24 05:50:56 sudo usermod -a -G libvirt centos
8 11/01/24 06:29:59 vi /etc/libvirt/libvirtd.conf
9 11/01/24 06:30:25 sudo vi /etc/libvirt/libvirtd.conf
10 11/01/24 06:31:33 sudo systemctl restart libvirtd.service
11 11/01/24 06:31:43 curl -LO
https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64
12 11/01/24 06:31:48 sudo install minikube-linux-amd64 /usr/local/bin/minikube
13 11/01/24 06:31:56 minikube version
14 11/01/24 06:32:13 curl -LO https://storage.googleapis.com/kubernetes-
release/release/`curl -s
https://storage.googleapis.com/kubernetes-release/release/stable.txt`/bin/linux/
amd64/kubectl
15 11/01/24 06:32:18 chmod +x kubectl
16 11/01/24 06:32:23 mv kubectl /usr/local/bin
17 11/01/24 06:32:31 sudo mv kubectl /usr/local/bin
18 11/01/24 06:32:36 kubectl version --client -o json
19 11/01/24 06:32:51 sudo yum install -y yum-utils
20 11/01/24 06:33:14 yum install -y yum-utils
21 11/01/24 06:33:16 yum-config-manager --add-repo
https://download.docker.com/linux/centos/docker-ce.repo
22 11/01/24 06:33:37 sudo yum install -y yum-utils yum-config-manager --add-
repo https://download.docker.com/linux/centos/docker-ce.repo
23 11/01/24 06:33:54 sudo yum-config-manager --add-repo
https://download.docker.com/linux/centos/docker-ce.repo
24 11/01/24 06:34:04 sudo yum install docker-ce docker-ce-cli containerd.io
docker-buildx-plugin docker-compose-plugin
25 11/01/24 06:36:00 docker version
26 11/01/24 06:36:14 systemctl enable --now docker
27 11/01/24 06:36:40 sudo systemctl enable --now docker
28 11/01/24 06:36:44 docker version
29 11/01/24 06:36:54 sudo docker version
30 11/01/24 06:37:29 sudo usermod -aG docker centos
31 11/01/24 06:37:41 sudo minikube start --driver=docker
32 11/01/24 06:38:25 minikube start --driver=docker
33 11/01/24 06:38:59 id centos
34 11/01/24 06:39:35 docker login
35 11/01/24 06:42:38 minikube start --driver=docker
36 11/01/24 06:44:26 kubectl
37 11/01/24 06:54:50 k9s
38 11/01/24 06:55:05 ps -ef|grep minikube
39 11/01/24 06:55:45 kubectl version --client
40 11/01/24 06:56:36 mkdir project
41 11/01/24 06:56:49 chmod -R 777 project/
42 11/01/24 06:56:50 cd project/
43 11/01/24 06:56:55 vi index-html-configmap1.yaml
44 11/01/24 06:57:43 kubectl apply -f index-html-configmap1.yaml
45 11/01/24 06:58:22 vi index-html-configmap2.yaml
46 11/01/24 06:58:37 kubectl apply -f index-html-configmap2.yaml
47 11/01/24 07:21:34 vi 2NGINXdeployments-services.yaml
48 11/01/24 07:21:56 kubebctl apply -f 2NGINXdeployments-services.yaml
49 11/01/24 07:22:24 kubectl apply -f 2NGINXdeployments-services.yaml
50 11/01/24 07:44:52 ls -lrt
51 11/01/24 07:46:36 vi 2NGINXdeployments-services.yaml
52 11/01/24 07:50:33 kubectl apply -f 2NGINXdeployments-services.yaml
53 11/01/24 07:51:06 mv NGINXdeployments-services.yaml NGINXdeployments-
services.yaml
54 11/01/24 07:51:18 mv 2NGINXdeployments-services.yaml NGINXdeployments-
services.yaml
55 11/01/24 07:51:27 kubectl apply -f NGINXdeployments-services.yaml
56 11/01/24 07:51:39 vi NGINXdeployments-services.yaml
57 11/01/24 07:52:55 mv NGINXdeployments-services.yaml 2NGINXdeployments-
services.yaml
58 11/01/24 07:53:09 vi NGINXdeployments-services.yaml
59 11/01/24 07:53:31 kubectl apply -f NGINXdeployments-services.yaml
60 11/01/24 07:54:31 kubectl describe deployment kubectl describe deployment
index-html-configmap1.yaml
61 11/01/24 07:55:02 kubectl describe replicaset
62 11/01/24 07:55:20 kubectl describe deployment kubectl describe deployment
index-html-configmap2.yaml
63 11/01/24 07:55:32 kubectl describe replicaset
64 11/01/24 07:55:53 kubectl logs deployment/index-html-configmap1.yaml
65 11/01/24 07:56:12 kubectl logs deployment/index-html-configmap2.yaml
66 11/01/24 07:56:25 kubectl get all
67 11/01/24 07:56:58 curl localhost:30052
68 11/01/24 07:57:42 ls
69 11/01/24 07:57:49 cat index-html-configmap1.yaml
70 11/01/24 08:00:25 curl localhost:30052
71 11/01/24 08:00:36 ps -ef|grep 80
72 11/01/24 08:00:48 netstat -a
73 11/01/24 08:01:31 ps -ef|grep kubectl
74 11/01/24 08:02:04 kubectl get pods
75 11/01/24 08:02:32 k9s
76 11/01/24 08:02:37 labauto
77 11/01/24 08:02:44 sudo labauto
78 11/01/24 08:02:51 k9s
79 11/01/24 08:03:34 history

You might also like