Installation of Kubernetes and KubeSphere on Linux
KubeSphere Container Platform:
KubeSphere is a distributed operating system for cloud-native application management, using Kubernetes as its kernel.
Open Source: A CNCF-certified Kubernetes platform, 100% open source, built and improved by the community.
Easy to Run: Can be deployed on an existing Kubernetes cluster or Linux machines, supports online and air-gapped installation.
Rich Features: Deliver DevOps, service mesh, observability, application management, multi-tenancy, storage and networking management in a unified platform.
Modular and Pluggable: The functionalities are modularized and loosely coupled with the platform. Choose the modules according to your business needs.
All-in-One Installation:
- Prepare Linux Machine
For Lab purpose i have created a VM with the following specs
- 8vCPU
- 16GB RAM
- 100GB free disk space
- Ubuntu 2204 with static IP
Create the Virtual Machines manually or using Packer template and clone using Terraform/OpenTofu. I have used the OpenTofu code, which will create VM with the required configuration
Tofu/terrform code to create kubesphere VM from template Login to kubesphere VM and run the following commands.
1sudo apt-get update
2sudo apt-get install socat conntrack ebtables ipset -y
- Download KubeKey from its GitHub Release Page or run the following command:
1curl -sfL https://get-kk.kubesphere.io | VERSION=v3.0.13 sh -
- Make kk executable
1chmod +x kk
- Create a Kubernetes cluster with KubeSphere installed, run the following command:
1sudo ./kk create cluster --with-kubernetes v1.22.12 --with-kubesphere v3.4.1
After running the command, will see a table for environment check. Type yes to continue.
The output displays the IP address and port number of the web console, which is exposed through NodePort 30880 by default.
In my case, i will be accessing using http://kubesphere.cloudbricks.local:30880 with the default account and password (admin/P@88w0rd).
Enable DevOps and App store:
Login to the Kubesphere URL and go to Cluster config
kubesphere Login page Go to CRDs, in the search
"clusterconfig"
, then click on clusterConfigurationCluster Config Under ks-installer click on edit YAML
edit Cluster config scroll through and
change devops enabled to True
enabling devops scroll through and
change openpitrix enabled to True
enabling Appstore
Wait for the changes to reflect, and relogin to the console to check App store