Skip to content

Commit

Permalink
docs: add required labels to required CRD fields (KeptnTask, KeptnMet…
Browse files Browse the repository at this point in the history
…ric, KeptnMetricsProvider, KeptnTaskDefintion) (#2388)
  • Loading branch information
mowies committed Oct 31, 2023
1 parent 5c7b0cd commit 0e39c0e
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 21 deletions.
8 changes: 4 additions & 4 deletions docs/content/en/docs/yaml-crd-ref/metric.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ spec:
## Fields

* **apiVersion** -- API version being used.
`

* **kind** -- Resource type.
Must be set to `KeptnMetric`.

Expand All @@ -51,7 +51,7 @@ spec:
* **namespace** -- Namespace of the application using this metric.

* **spec**
* **provider.name** --
* **provider.name** (required) --
Name of this instance of the data source
from which the metric is collected.
This value must match the value of the `metadata.name` field
Expand All @@ -64,9 +64,9 @@ spec:
as the name of the Prometheus server that monitors the dev deployment
and `prod-prometheus` as the name of the Prometheus server
that monitors the production deployment.
* **query** -- String in the provider-specific query language,
* **query** (required) -- String in the provider-specific query language,
used to obtain a metric.
* **fetchIntervalSeconds** -- Number of seconds between updates of the metric.
* **fetchIntervalSeconds** (required) -- Number of seconds between updates of the metric.
* **range**
* **interval** -- Timeframe for which the metric would be queried.
Defaults to 5m.
Expand Down
4 changes: 2 additions & 2 deletions docs/content/en/docs/yaml-crd-ref/metricsprovider.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@ spec:

* **spec**

* **type** -- The type of data provider for this instance
* **targetServer** -- URL of the data provider, enclosed in double quotes
* **type** (required) -- The type of data provider for this instance
* **targetServer** (required) -- URL of the data provider, enclosed in double quotes
* **secretKeyRef**
* **name:** -- Name of the token for this data provider
* **key:** -- Key for this data provider
Expand Down
24 changes: 12 additions & 12 deletions docs/content/en/docs/yaml-crd-ref/task.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,50 +50,50 @@ spec:
[Kubernetes Object Names and IDs](https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names)
specification.
* **spec** - Defines the speficication of this `KeptnTask` resource
* **taskDefinition** - Name of the corresponding `KeptnTaskDefinition` resource.
* **taskDefinition** (required) -- Name of the corresponding `KeptnTaskDefinition` resource.
This `KeptnTaskDefinition` can be located in the same namespace
or in the Keptn installation namespace.
* **context** - Contextual information about the task execution
* **appName** - Name of the
* **context** (required) -- Contextual information about the task execution
* **appName** (required) -- Name of the
[KeptnApp](../yaml-crd-ref/app.md) resource
for which the `KeptnTask` is being executed.
* **appVersion** - Version of the `KeptnApp` resource
* **appVersion** (required) -- Version of the `KeptnApp` resource
for which the `KeptnTask` is being executed.

* **objectType** - Indicates whether this `KeptnTask`
* **objectType** (required) -- Indicates whether this `KeptnTask`
is being executed for a `KeptnApp` or a `KeptnWorkload` resource.
When populating this resource manually
to run a task for a non-Kubernetes deployment,
set this value to `""`:
Keptn populates this field based on annotations
to the `KeptnWorkload` and `KeptnApp` resources.

* **taskType** Indicates whether this `KeptnTask`
* **taskType** (required) -- Indicates whether this `KeptnTask`
is part of the pre- or post-deployment phase.
When populating this resource manually
to run a task for a non-Kubernetes deployment,
set this value to `""`:
Keptn populates this field based on annotations
to the `KeptnWorkload` and `KeptnApp` resources.

* **workloadName** - Name of the `KeptnWorkload`
* **workloadName** (required) -- Name of the `KeptnWorkload`
for which the `KeptnTask` is being executed.
* **workloadVersion** - Version of the `KeptnWorkload`
* **workloadVersion** (required) -- Version of the `KeptnWorkload`
for which the `KeptnTask` is being executed.
* **parameters** (optional) -- Parameters that are passed to the job
* **parameters** -- Parameters that are passed to the job
that executes the `KeptnTask`.
* **secureParameters** (optional) -- Secure parameters that are passed
* **secureParameters** -- Secure parameters that are passed
to the job that executes the `KeptnTask`.
These are stored and accessed as Kubernetes `Secrets` in the cluster.
See [Working with secrets](../implementing/tasks/#working-with-secrets)
for more information.
* **checkType** -- Defines whether task is part of pre- or post-deployment phase.
Keptn populates this field based on annotations
to the `KeptnWorkload` and `KeptnApp` resources.
* **retries** (optional) -- If errors occur,
* **retries** -- If errors occur,
this defines the number of attempts made
before the `KeptnTask` is considered to be failed.
* **timeout** (optional) -- Specifies the time, in seconds,
* **timeout** -- Specifies the time, in seconds,
to wait for the `KeptnTask` to complete successfully.
If the `KeptnTask` does not complete successfully in this timeframe,
it is considered to be failed.
Expand Down
6 changes: 3 additions & 3 deletions docs/content/en/docs/yaml-crd-ref/taskdefinition.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ spec:
[Kubernetes Object Names and IDs](https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names)
specification.
* **spec**
* **deno | python | container** -- Define the container type
* **deno | python | container** (required) -- Define the container type
to use for this task.
Each task can use one type of runner,
identified by this field:
Expand All @@ -107,10 +107,10 @@ spec:
and code the functionality to match the container you define.
See
[Synopsis for container-runtime container](#synopsis-for-container-runtime).
* **retries** (optional) -- specifies the number of times
* **retries** -- specifies the number of times
a job executing the `KeptnTaskDefinition`
should be restarted if an attempt is unsuccessful.
* **timeout** (optional) -- specifies the maximum time
* **timeout** -- specifies the maximum time
to wait for the task to be completed successfully.
The value supplied should specify the unit of measurement;
for example, `5s` indicates 5 seconds and `5m` indicates 5 minutes.
Expand Down

0 comments on commit 0e39c0e

Please sign in to comment.