Skip to content

Commit

Permalink
Merge pull request #106 from deefreak/ossrefactoringsnew
Browse files Browse the repository at this point in the history
Installation guide changes
  • Loading branch information
bharathguvvala authored Jan 15, 2024
2 parents 7beece4 + 171d80a commit 75b5544
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 2 deletions.
15 changes: 13 additions & 2 deletions INSTALLATION.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Ottoscalr can be installed in any kubernetes cluster which meets the prerequisit
## Building the image

The following section outlines the docker image build process for the ottoscalr.
The following commands builds the image for the platform linux/amd64. Change the TARGETOS and TARGETARCH if it is required to be built for other platform.
The following commands builds the image for the platform linux/amd64. Change the TARGETOS and TARGETARCH if it is required to be built for other platform. Run this from the root directory of the project.
```console
$ TARGETOS=linux;TARGETARCH=amd64;make docker-build docker-push IMG={repository}:{tag}
```
Expand All @@ -21,7 +21,17 @@ $ TARGETOS=linux;TARGETARCH=amd64;make docker-build docker-push IMG={repository}

Ottoscalr can be deployed via this [helm chart](https://github.com/flipkart-incubator/ottoscalr/tree/main/charts/ottoscalr).

This chart bootstraps ottoscalr on a Kubernetes cluster using the Helm package manager. As part of that, it will install all the required Custom Resource Definitions (CRD).
This chart bootstraps ottoscalr on a Kubernetes cluster using the Helm package manager. As part of that, it will install all the required Custom Resource Definitions (CRD) which introduces the following kinds:

```
apiVersion: ottoscaler.io/v1alpha1
kind: PolicyRecommendation
```
```
apiVersion: ottoscaler.io/v1alpha1
kind: Policy
```


### Installing the Chart

Expand Down Expand Up @@ -64,6 +74,7 @@ their default values.
| `image.tag` | string | `""` | Image tag of ottoscalr deployment |
| `replicaCount` | int | `1` | Capability to configure the number of replicas for ottoscalr operator. While you can run more replicas of our operator, only one operator instance will be the leader and serving traffic. You can run multiple replicas, but they will not improve the performance of ottoscalr, it could only reduce downtime during a failover. |
| `resources` | object | `{"limits":{"cpu":2,"memory":"4Gi"},"requests":{"cpu":"2","memory":"4Gi"}}` | Manage resource request & limits of ottoscalr operator pod |
| `serviceMonitor.create` | bool | `true` | If true, this will export [ottoscalr metrics](https://github.com/flipkart-incubator/ottoscalr/blob/main/OTTOSCALR_METRICS.md). |

#### Operations

Expand Down
2 changes: 2 additions & 0 deletions charts/ottoscalr/templates/servicemonitor.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
{{- if .Values.serviceMonitor.create -}}
apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
Expand Down Expand Up @@ -28,3 +29,4 @@ spec:
selector:
matchLabels:
app: ottoscalr
{{- end }}
3 changes: 3 additions & 0 deletions charts/ottoscalr/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ serviceAccount:
# If not set and create is true, a name is generated using the fullname template
name: "ottoscalr"

serviceMonitor:
create: true

podAnnotations: {}

podSecurityContext: {}
Expand Down

0 comments on commit 75b5544

Please sign in to comment.