instructions
The following instructions can be found in the official website. I’ve just added some of the narrative and screenshots of how we did it. It’s mainly practice! Hope big guy don’t spray yo ~ ha ha
First, plug-in installation and opening
1 Enabling the App Store plug-in
KubeSphere provides users with a Helm-based app store for application lifecycle management on top of OpenPitrix.
OpenPitrix is an open source Web platform for packaging, deploying, and managing different types of applications. The KubeSphere App Store enables isVs, developers and users to upload, test, deploy and publish applications in a one-stop shop with just a few clicks.
Since we initially installed Kubesphere with minimal installation, most of the plug-ins were not installed, so we need to modify the configuration and then open the relevant plug-ins.
Enable the App Store after installation
Operation steps:
- Log in to the console as admin, click Platform Management in the upper left corner, and select Cluster Management.
- Click custom resource CRD, enter ClusterConfiguration in the search box, and click the result to view its details.
- In the resource list, click on the right of Ks-Installer and select Edit Configuration file.
- In the YAML file, search for OpenPitrix and change the enabled false to true. When you’re done, click on the update in the lower right corner to save the configuration.
5: Use the Web Kubectl tool to execute the following command to check the installation process:
PS: If you have other plug-ins that need to be enabled, agree to enable them before executing the following.
kubectl logs -n kubesphere-system $(kubectl get pod -n kubesphere-system -l app=ks-install -o jsonpath='{.items[0].metadata.name}') -f
Copy the code
2 Enable the DevOps plug-in
It is mainly used for CI/CD workflow design. Provides a comprehensive, visual CI/CD pipeline.
Enable DevOps after installation
Procedure: Ensure that the Settings are consistent with those for enabling applications. The main difference is where the reconfiguration file is opened.
~ omit 1,2,3, steps!
4: Search for devops in the YAML file and change the enabled false to true. When you’re done, click on the update in the lower right corner to save the configuration.
5: Use the Web Kubectl tool to execute the following command to check the installation process:
PS: If you have other plug-ins that need to be enabled, agree to enable them before executing the following.
kubectl logs -n kubesphere-system $(kubectl get pod -n kubesphere-system -l app=ks-install -o jsonpath='{.items[0].metadata.name}') -f
Copy the code
3 Start the KubeSphere log system
KubeSphere provides a powerful, comprehensive, and easy-to-use logging system for log collection, query, and management. It covers logging at different levels, including tenants, infrastructure resources, and applications. Users can search logs from different dimensions such as project, workload, Pod, and keyword.
Procedure: Ensure that the Settings are consistent with those for enabling applications. The main difference is where the reconfiguration file is opened.
~ omit 1,2,3, steps!
4: Search for devops in the YAML file and change the enabled false to true. When you’re done, click on the update in the lower right corner to save the configuration.
5: Use the Web Kubectl tool to execute the following command to check the installation process:
PS: If you have other plug-ins that need to be enabled, agree to enable them before executing the following.
kubectl logs -n kubesphere-system $(kubectl get pod -n kubesphere-system -l app=ks-install -o jsonpath='{.items[0].metadata.name}') -f
Copy the code
4. Execute the update operation (wait for plug-in installation) :
5. Log in again to verify the installation
Some plug-ins fail to be installed. Check the cause
Installation failure does not care about it, after a long process! It will automatically heal itself! It should be the network! Causes problems when reinstalling parts of the plug-in! So be patient!
The final installation is as follows:
Plugin app Store
1. Install PostgresQL
Corresponding to our application installation, the existing application can be directly used.
Operation steps:
- Log in to the console as project-regular.
2: Go to the app Store.
3: View the application and click Deploy
4: Enter application information
5: Next, set the password
6: Click Deploy
7: View applications
8: Open the service page
9: Enable edit Extranet access
10: Confirm service port:
11: Naticat Service Link:
2. Install Redis
Operation steps:
- Log in to the console as project-regular.
Choose to deploy a new application:
2: Go to the app Store.
3: Click Deploy
4: Fill in basic information
5: Set the redis password
6: Click Deploy
7: After creation, verify availability in container group
- By default, his service is a Hesadless service
- Verify availability in container groups
3. Log system of plug-in (log collection of falling disk)
1. Enable the fall disk log collection function
Note that this is the project-admin identity
- In order to
project-admin
Log in to KubeSphere’s Web console as an identity and enter the project.
- I’m gonna go ahead and select the project
- In the left navigation bar, select Advanced Settings in Project Settings. Under the drop disk log collection column, enable this function by toggling the switch.
2. Deploy application verification
2.1 Creating an Application
In the left navigation bar, select the workload in Application Workload. Under the Deployment TAB, click Create.
2.2 Configuring Application Information
Dialog box, set the name of the deployment (for example, Demo-Deployment) and click Next.
2.3 Configuring application Containers
Under the container image, click Add Alpine Container Image
2.4 Configuring Container Startup Commands
Scroll and check the start command. Enter the following values in the run command and parameters, click √, and then click Next.
Run the command
/bin/sh
Copy the code
parameter
-c,if [ ! -d /data/log ]; then mkdir -p /data/log; fi; while true; do date >> /data/log/app-test.log; sleep 30; doneCopy the code
note
The above commands and parameters mean that the date information is exported to app-test.log every 30 seconds in /data/log.
2.5 Attaching Storage Volumes to Containers
Under the Mount Storage TAB, enable drop disk log collection and click Add Storage Volume.
2.6 Storage Volume Configuration
PS: Since it is only for validation tests, you can use temporary storage volumes!
Under the temporary volume TAB, enter the volume name (for example, demo-disk-log-collection), set the access mode and path, click √, and then click Next to continue.
2.7 Creation Completed
2.8 Waiting for the Creation result
3. View application logs
3.1 Access Application Details
Under the Deployment TAB, click the deployment you just created to access its details page.
3.2 Using the FileBeat Container – Check disk drop logs
Click deploy Application in container group:
In resource status, click the arrow on the right to view container details. Then click the logSidecar – Container (FileBeat Container) log icon to check disk drop logs.
3.3 throughThe toolkitIn theLog queryFunctional view
Use the name of the deployment (for example, Demo-Deployment) for fuzzy matching
The above is a brief description of some plugins to enable and use.
At the end
END
Jane: www.jianshu.com/u/d6960089b…
The Denver nuggets: juejin. Cn/user / 296393…
Public account: wechat search [children to a pot of wolfberry wine tea]
Let students | article | QQ: welcome to learn communication 】 【 308711822
- 1: The description in this paper is mainly my cognition and opinion. If there is any improper place, I hope you can correct me.
- 2: About the content of the article, part of the content is arranged from the Internet, if there is a link will be declared annotation; If there is no timely annotation of the link, if there is infringement please contact, I will immediately delete processing yo.