Skip to content

Commit

Permalink
chore: readme (#107)
Browse files Browse the repository at this point in the history
Signed-off-by: Alex Jones <alexsimonjones@gmail.com>
  • Loading branch information
AlexsJones committed May 18, 2023
1 parent 49427c9 commit c58f8b4
Showing 1 changed file with 45 additions and 23 deletions.
68 changes: 45 additions & 23 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
This Operator is designed to enable [K8sGPT](https://github.com/k8sgpt-ai/k8sgpt/) within a Kubernetes cluster.
It will allow you to create a custom resource that defines the behaviour and scope of a managed K8sGPT workload. Analysis and outputs will also be configurable to enable integration into existing workflows.

<img src="images/demo2.gif" width="600px;"/>

## Installation

Expand All @@ -19,8 +20,6 @@ helm install release k8sgpt/k8sgpt-operator -n k8sgpt-operator-system --create-n

## Run the example

<img src="images/demo2.gif" width="600px;"/>

1. Install the operator from the [Installation](#installation) section.

2. Create secret:
Expand Down Expand Up @@ -62,19 +61,52 @@ you will be able to see the Results objects of the analysis after some minutes (
{
"apiVersion": "core.k8sgpt.ai/v1alpha1",
"kind": "Result",
"metadata": {
"creationTimestamp": "2023-04-26T09:45:02Z",
"generation": 1,
"name": "placementoperatorsystemplacementoperatorcontrollermanagermetricsservice",
"namespace": "default",
"resourceVersion": "108371",
"uid": "f0edd4de-92b6-4de2-ac86-5bb2b2da9736"
},
"spec": {
"details": "The error message means that the service in Kubernetes doesn't have any associated endpoints, which should have been labeled with \"control-plane=controller-manager\". \n\nTo solve this issue, you need to add the \"control-plane=controller-manager\" label to the endpoint that matches the service. Once the endpoint is labeled correctly, Kubernetes can associate it with the service, and the error should be resolved.",
```
## LocalAI Example
## Other AI Backend Examples
<details>
<summary>AzureOpenAI</summary>
1. Install the operator from the [Installation](#installation) section.
2. Create secret:
```sh
kubectl create secret generic k8sgpt-sample-secret --from-literal=azure-api-key=$AZURE_TOKEN -n k8sgpt-
operator-system
```
3. Apply the K8sGPT configuration object:
```
kubectl apply -f - << EOF
apiVersion: core.k8sgpt.ai/v1alpha1
kind: K8sGPT
metadata:
name: k8sgpt-sample
namespace: k8sgpt-operator-system
spec:
model: gpt-35-turbo
backend: azureopenai
baseUrl: https://k8sgpt.openai.azure.com/
engine: llm
noCache: false
version: v0.3.2
enableAI: true
secret:
name: k8sgpt-sample-secret
key: azure-api-key
EOF
```
</details>
<details>
<summary>LocalAI</summary>
1. Install the operator from the [Installation](#installation) section.
Expand All @@ -99,18 +131,8 @@ EOF
4. Same as step 4. in the example above.
## Architecture
<img src="images/1.png" width="600px;" />
</details>
## Helm values
Here is an example of some of the values that can be configured.
For more details please see [here](chart/values.yaml)
| Parameter | Description | Default |
| --------- | ----------- | ------- |
| `serviceMonitor.enabled` | Enable Prometheus Operator ServiceMonitor | `false` |
| `controllerManager.manager.image.repository` | Image repository | `k8sgpt/k8sgpt-operator` |
| `controllerManager.manager.image.pullPolicy` | Image pull policy | `IfNotPresent` |
| `controllerManager.manager.imagePullSecrets` | Image pull secrets | `[]` |
For details please see [here](chart/values.yaml)

0 comments on commit c58f8b4

Please sign in to comment.