Skip to content

Commit

Permalink
Update keptn-metrics-operator Helm chart (#111)
Browse files Browse the repository at this point in the history
Signed-off-by: GitHub <[email protected]>
Co-authored-by: odubajDT <[email protected]>
  • Loading branch information
keptn-bot and odubajDT committed Jan 15, 2024
1 parent 126da42 commit 7ccd659
Show file tree
Hide file tree
Showing 22 changed files with 871 additions and 59 deletions.
6 changes: 6 additions & 0 deletions charts/keptn-metrics-operator/Chart.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
dependencies:
- name: common
repository: https://charts.lifecycle.keptn.sh
version: 0.1.1
digest: sha256:e23ec46850d32494b1956923b8cf43dd06187dfe49a7be033778be9938f092d1
generated: "2024-01-08T11:50:17.289101+01:00"
4 changes: 2 additions & 2 deletions charts/keptn-metrics-operator/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ version: 0.1.0
# incremented each time you make changes to the application. Versions are not expected to
# follow Semantic Versioning. They should reflect the version the application is using.
# It is recommended to use it with quotes.
appVersion: "v0.8.3" # x-release-please-version
appVersion: "v0.9.0" # x-release-please-version
dependencies:
- name: common
repository: "https://charts.lifecycle.keptn.sh"
version: 0.1.0
version: 0.1.1
4 changes: 2 additions & 2 deletions charts/keptn-metrics-operator/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ Prometheus, Dynatrace, DataDog and K8s metric server...
| `annotations` | add deployment level annotations | `{}` |
| `podAnnotations` | adds pod level annotations | `{}` |
| `kubernetesClusterDomain` | overrides cluster.local | `cluster.local` |
| `customMetricsAPIService.enabled` | enable/disable the K8s APIService installation | `true` |

### Keptn Metrics Operator controller

Expand All @@ -70,12 +71,11 @@ Prometheus, Dynatrace, DataDog and K8s metric server...
| `containerSecurityContext.runAsUser` | | `65532` |
| `containerSecurityContext.seccompProfile.type` | | `RuntimeDefault` |
| `env.exposeKeptnMetrics` | enable metrics exporter | `true` |
| `env.enableKeptnAnalysis` | enables/disables the analysis feature | `false` |
| `env.metricsControllerLogLevel` | sets the log level of Metrics Controller | `0` |
| `env.analysisControllerLogLevel` | sets the log level of Analysis Controller | `0` |
| `image.registry` | specify the container registry for the metrics-operator image | `ghcr.io` |
| `image.repository` | specify registry for manager image | `keptn/metrics-operator` |
| `image.tag` | select tag for manager image | `v0.8.3` |
| `image.tag` | select tag for manager image | `v0.9.0` |
| `imagePullPolicy` | specify pull policy for manager image | `Always` |
| `livenessProbe` | custom livenessprobe for manager container | |
| `readinessProbe` | custom readinessprobe for manager container | |
Expand Down
163 changes: 161 additions & 2 deletions charts/keptn-metrics-operator/templates/analysis-crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.13.0
cert-manager.io/inject-ca-from: '{{ .Release.Namespace }}/keptn-certs'
{{- include "common.annotations" ( dict "context" . ) }}
labels:
app.kubernetes.io/part-of: keptn-lifecycle-toolkit
app.kubernetes.io/part-of: keptn
crdGroup: metrics.keptn.sh
keptn.sh/inject-cert: "true"
{{- include "common.labels.standard" ( dict "context" . ) | nindent 4 }}
{{- include "common.annotations" ( dict "context" . ) }}
spec:
group: metrics.keptn.sh
names:
Expand Down Expand Up @@ -176,6 +176,165 @@ spec:
type: object
type: object
served: true
storage: false
subresources:
status: {}
- additionalPrinterColumns:
- jsonPath: .spec.analysisDefinition.name
name: AnalysisDefinition
type: string
- jsonPath: .status.state
name: State
type: string
- jsonPath: .status.warning
name: Warning
type: string
- jsonPath: .status.pass
name: Pass
type: string
name: v1beta1
schema:
openAPIV3Schema:
description: Analysis is the Schema for the analyses API
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
spec:
description: AnalysisSpec defines the desired state of Analysis
properties:
analysisDefinition:
description: AnalysisDefinition refers to the AnalysisDefinition,
a CRD that stores the AnalysisValuesTemplates
properties:
name:
description: Name defines the name of the referenced object
type: string
namespace:
description: Namespace defines the namespace of the referenced
object
type: string
required:
- name
type: object
args:
additionalProperties:
type: string
description: Args corresponds to a map of key/value pairs that can
be used to substitute placeholders in the AnalysisValueTemplate
query. i.e. for args foo:bar the query could be "query:percentile(95)?scope=tag(my_foo_label:{{.foo}})".
type: object
timeframe:
description: Timeframe specifies the range for the corresponding query
in the AnalysisValueTemplate. Please note that either a combination
of 'from' and 'to' or the 'recent' property may be set. If neither
is set, the Analysis can not be added to the cluster.
properties:
from:
description: From is the time of start for the query. This field
follows RFC3339 time format
format: date-time
type: string
recent:
description: Recent describes a recent timeframe using a duration
string. E.g. Setting this to '5m' provides an Analysis for the
last five minutes
pattern: ^0|([0-9]+(\.[0-9]+)?(ns|us|µs|ms|s|m|h))+$
type: string
to:
description: To is the time of end for the query. This field follows
RFC3339 time format
format: date-time
type: string
type: object
required:
- analysisDefinition
- timeframe
type: object
status:
description: AnalysisStatus stores the status of the overall analysis
returns also pass or warnings
properties:
pass:
description: Pass returns whether the SLO is satisfied
type: boolean
raw:
description: Raw contains the raw result of the SLO computation
type: string
state:
description: State describes the current state of the Analysis (Pending/Progressing/Completed)
type: string
storedValues:
additionalProperties:
description: ProviderResult stores reference of already collected
provider query associated to its objective template
properties:
errMsg:
description: ErrMsg stores any possible error at retrieval time
type: string
objectiveReference:
description: Objective store reference to corresponding objective
template
properties:
name:
description: Name defines the name of the referenced object
type: string
namespace:
description: Namespace defines the namespace of the referenced
object
type: string
required:
- name
type: object
query:
description: Query represents the executed query
type: string
value:
description: Value is the value the provider returned
type: string
type: object
description: StoredValues contains all analysis values that have already
been retrieved successfully
type: object
timeframe:
description: Timeframe describes the time frame which is evaluated
by the Analysis
properties:
from:
description: From is the time of start for the query. This field
follows RFC3339 time format
format: date-time
type: string
recent:
description: Recent describes a recent timeframe using a duration
string. E.g. Setting this to '5m' provides an Analysis for the
last five minutes
pattern: ^0|([0-9]+(\.[0-9]+)?(ns|us|µs|ms|s|m|h))+$
type: string
to:
description: To is the time of end for the query. This field follows
RFC3339 time format
format: date-time
type: string
type: object
warning:
description: Warning returns whether the analysis returned a warning
type: boolean
required:
- state
- timeframe
type: object
type: object
served: true
storage: true
subresources:
status: {}
Loading

0 comments on commit 7ccd659

Please sign in to comment.