Skip to content

Commit

Permalink
fix: add variable to deactivate the output of Helm templates on plan (#…
Browse files Browse the repository at this point in the history
…82)

* fix: add variable to deactivate the output of Helm templates on plan

* docs: add missing hyperlink on the sidebar

* docs(terraform-docs): generate docs and write to README.adoc

* docs: fix chart version attribute on the README.adoc

* docs: add better formatting to some descriptions

* docs(terraform-docs): generate docs and write to README.adoc

* chore: accept code review suggestions

* docs(terraform-docs): generate docs and write to README.adoc

---------

Co-authored-by: lentidas <lentidas@users.noreply.github.com>
  • Loading branch information
lentidas and lentidas authored Aug 14, 2023
1 parent 9a1c00d commit a31abf3
Show file tree
Hide file tree
Showing 8 changed files with 213 additions and 114 deletions.
65 changes: 41 additions & 24 deletions README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ The kube-prometheus-stack chart used by this module is shipped in this repositor
[cols="1,1,1",options="autowidth,header"]
|===
|Current Chart Version |Original Repository |Default Values
|*{chart-version}* |{chart-url}[Chart] |https://artifacthub.io/packages/helm/prometheus-community/kube-prometheus-stack/{chart-version}?modal=values[`values.yaml`]
|*{kube-prometheus-stack-chart-version}* |{chart-url}[Chart] |https://artifacthub.io/packages/helm/prometheus-community/kube-prometheus-stack/{chart-version}?modal=values[`values.yaml`]
|===

*Since this module is meant to be instantiated using its variants, the usage documentation is available in each variant* ( xref:./aks/README.adoc[AKS] | xref:./eks/README.adoc[EKS] | xref:./kind/README.adoc[KinD] | xref:./sks/README.adoc[SKS] ).
Expand Down Expand Up @@ -38,12 +38,12 @@ The following requirements are needed by this module:

The following providers are used by this module:

- [[provider_random]] <<provider_random,random>> (>= 3)

- [[provider_null]] <<provider_null,null>> (>= 3)

- [[provider_kubernetes]] <<provider_kubernetes,kubernetes>> (>= 2)

- [[provider_random]] <<provider_random,random>> (>= 3)

- [[provider_utils]] <<provider_utils,utils>> (>= 1)

- [[provider_helm]] <<provider_helm,helm>>
Expand Down Expand Up @@ -100,7 +100,7 @@ Description: Override of target revision of the application chart.

Type: `string`

Default: `"v6.0.0"`
Default: `"v6.1.0"`

==== [[input_cluster_issuer]] <<input_cluster_issuer,cluster_issuer>>

Expand Down Expand Up @@ -134,6 +134,15 @@ Type: `bool`

Default: `false`

==== [[input_show_manifest_diff]] <<input_show_manifest_diff,show_manifest_diff>>

Description: A boolean to enable/disable outputting Helm templates on the Terraform plan.
This is useful for debugging purposes only. *Make sure no secrets appear in the Kubernetes manifests before setting this flag, otherwise they will be exposed in your Terraform plan.*

Type: `bool`

Default: `false`

==== [[input_app_autosync]] <<input_app_autosync,app_autosync>>

Description: Automated sync options for the Argo CD Application resource.
Expand Down Expand Up @@ -186,15 +195,15 @@ Default: `{}`

Description: Object containing Alertmanager settings. The following attributes are supported:

* enabled: whether Alertmanager is deployed or not (default: `true`).
* domain: domain name configured in the Ingress (default: `prometheus.apps.${var.cluster_name}.${var.base_domain}`).
* oidc: OIDC configuration to be used by oauth2_proxy in front of Alertmanager (Mandatory).
* deadmanssnitch_url: url of a Dead Man's Snitch service Alertmanager should report to (by default this reporing is disabled).
* slack_routes: list of objects configuring routing of alerts to Slack channels, with the following attributes:
* name: name of the configured route.
* channel: channel where the alerts will be sent (with '#').
* api_url: slack URL you received when configuring a webhook integration.
* matchers: list of strings for filtering which alerts will be sent.
* `enabled`: whether Alertmanager is deployed or not (default: `true`).
* `domain`: domain name configured in the Ingress (default: `prometheus.apps.${var.cluster_name}.${var.base_domain}`).
* `oidc`: OIDC configuration to be used by OAuth2 Proxy in front of Alertmanager (**required**).
* `deadmanssnitch_url`: url of a Dead Man's Snitch service Alertmanager should report to (by default this reporing is disabled).
* `slack_routes`: list of objects configuring routing of alerts to Slack channels, with the following attributes:
* `name`: name of the configured route.
* `channel`: channel where the alerts will be sent (with '#').
* `api_url`: slack URL you received when configuring a webhook integration.
* `matchers`: list of strings for filtering which alerts will be sent.

Type: `any`

Expand Down Expand Up @@ -244,11 +253,11 @@ Description: The admin password for Grafana.
[cols="a,a",options="header,autowidth"]
|===
|Name |Version
|[[provider_null]] <<provider_null,null>> |>= 3
|[[provider_kubernetes]] <<provider_kubernetes,kubernetes>> |>= 2
|[[provider_random]] <<provider_random,random>> |>= 3
|[[provider_utils]] <<provider_utils,utils>> |>= 1
|[[provider_helm]] <<provider_helm,helm>> |n/a
|[[provider_null]] <<provider_null,null>> |>= 3
|[[provider_argocd]] <<provider_argocd,argocd>> |>= 5
|===
Expand Down Expand Up @@ -296,7 +305,7 @@ Description: The admin password for Grafana.
|[[input_target_revision]] <<input_target_revision,target_revision>>
|Override of target revision of the application chart.
|`string`
|`"v6.0.0"`
|`"v6.1.0"`
|no
|[[input_cluster_issuer]] <<input_cluster_issuer,cluster_issuer>>
Expand All @@ -323,6 +332,14 @@ Description: The admin password for Grafana.
|`false`
|no
|[[input_show_manifest_diff]] <<input_show_manifest_diff,show_manifest_diff>>
|A boolean to enable/disable outputting Helm templates on the Terraform plan.
This is useful for debugging purposes only. *Make sure no secrets appear in the Kubernetes manifests before setting this flag, otherwise they will be exposed in your Terraform plan.*
|`bool`
|`false`
|no
|[[input_app_autosync]] <<input_app_autosync,app_autosync>>
|Automated sync options for the Argo CD Application resource.
|
Expand Down Expand Up @@ -370,15 +387,15 @@ object({
|[[input_alertmanager]] <<input_alertmanager,alertmanager>>
|Object containing Alertmanager settings. The following attributes are supported:
* enabled: whether Alertmanager is deployed or not (default: `true`).
* domain: domain name configured in the Ingress (default: `prometheus.apps.${var.cluster_name}.${var.base_domain}`).
* oidc: OIDC configuration to be used by oauth2_proxy in front of Alertmanager (Mandatory).
* deadmanssnitch_url: url of a Dead Man's Snitch service Alertmanager should report to (by default this reporing is disabled).
* slack_routes: list of objects configuring routing of alerts to Slack channels, with the following attributes:
* name: name of the configured route.
* channel: channel where the alerts will be sent (with '#').
* api_url: slack URL you received when configuring a webhook integration.
* matchers: list of strings for filtering which alerts will be sent.
* `enabled`: whether Alertmanager is deployed or not (default: `true`).
* `domain`: domain name configured in the Ingress (default: `prometheus.apps.${var.cluster_name}.${var.base_domain}`).
* `oidc`: OIDC configuration to be used by OAuth2 Proxy in front of Alertmanager (**required**).
* `deadmanssnitch_url`: url of a Dead Man's Snitch service Alertmanager should report to (by default this reporing is disabled).
* `slack_routes`: list of objects configuring routing of alerts to Slack channels, with the following attributes:
* `name`: name of the configured route.
* `channel`: channel where the alerts will be sent (with '#').
* `api_url`: slack URL you received when configuring a webhook integration.
* `matchers`: list of strings for filtering which alerts will be sent.
|`any`
|`{}`
Expand Down
57 changes: 37 additions & 20 deletions aks/README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ Description: Override of target revision of the application chart.

Type: `string`

Default: `"v6.0.0"`
Default: `"v6.1.0"`

==== [[input_cluster_issuer]] <<input_cluster_issuer,cluster_issuer>>

Expand Down Expand Up @@ -123,6 +123,15 @@ Type: `bool`

Default: `false`

==== [[input_show_manifest_diff]] <<input_show_manifest_diff,show_manifest_diff>>

Description: A boolean to enable/disable outputting Helm templates on the Terraform plan.
This is useful for debugging purposes only. *Make sure no secrets appear in the Kubernetes manifests before setting this flag, otherwise they will be exposed in your Terraform plan.*

Type: `bool`

Default: `false`

==== [[input_app_autosync]] <<input_app_autosync,app_autosync>>

Description: Automated sync options for the Argo CD Application resource.
Expand Down Expand Up @@ -175,15 +184,15 @@ Default: `{}`

Description: Object containing Alertmanager settings. The following attributes are supported:

* enabled: whether Alertmanager is deployed or not (default: `true`).
* domain: domain name configured in the Ingress (default: `prometheus.apps.${var.cluster_name}.${var.base_domain}`).
* oidc: OIDC configuration to be used by oauth2_proxy in front of Alertmanager (Mandatory).
* deadmanssnitch_url: url of a Dead Man's Snitch service Alertmanager should report to (by default this reporing is disabled).
* slack_routes: list of objects configuring routing of alerts to Slack channels, with the following attributes:
* name: name of the configured route.
* channel: channel where the alerts will be sent (with '#').
* api_url: slack URL you received when configuring a webhook integration.
* matchers: list of strings for filtering which alerts will be sent.
* `enabled`: whether Alertmanager is deployed or not (default: `true`).
* `domain`: domain name configured in the Ingress (default: `prometheus.apps.${var.cluster_name}.${var.base_domain}`).
* `oidc`: OIDC configuration to be used by OAuth2 Proxy in front of Alertmanager (**required**).
* `deadmanssnitch_url`: url of a Dead Man's Snitch service Alertmanager should report to (by default this reporing is disabled).
* `slack_routes`: list of objects configuring routing of alerts to Slack channels, with the following attributes:
* `name`: name of the configured route.
* `channel`: channel where the alerts will be sent (with '#').
* `api_url`: slack URL you received when configuring a webhook integration.
* `matchers`: list of strings for filtering which alerts will be sent.

Type: `any`

Expand Down Expand Up @@ -292,7 +301,7 @@ object({
|[[input_target_revision]] <<input_target_revision,target_revision>>
|Override of target revision of the application chart.
|`string`
|`"v6.0.0"`
|`"v6.1.0"`
|no

|[[input_cluster_issuer]] <<input_cluster_issuer,cluster_issuer>>
Expand All @@ -319,6 +328,14 @@ object({
|`false`
|no

|[[input_show_manifest_diff]] <<input_show_manifest_diff,show_manifest_diff>>
|A boolean to enable/disable outputting Helm templates on the Terraform plan.
This is useful for debugging purposes only. *Make sure no secrets appear in the Kubernetes manifests before setting this flag, otherwise they will be exposed in your Terraform plan.*

|`bool`
|`false`
|no

|[[input_app_autosync]] <<input_app_autosync,app_autosync>>
|Automated sync options for the Argo CD Application resource.
|
Expand Down Expand Up @@ -366,15 +383,15 @@ object({
|[[input_alertmanager]] <<input_alertmanager,alertmanager>>
|Object containing Alertmanager settings. The following attributes are supported:

* enabled: whether Alertmanager is deployed or not (default: `true`).
* domain: domain name configured in the Ingress (default: `prometheus.apps.${var.cluster_name}.${var.base_domain}`).
* oidc: OIDC configuration to be used by oauth2_proxy in front of Alertmanager (Mandatory).
* deadmanssnitch_url: url of a Dead Man's Snitch service Alertmanager should report to (by default this reporing is disabled).
* slack_routes: list of objects configuring routing of alerts to Slack channels, with the following attributes:
* name: name of the configured route.
* channel: channel where the alerts will be sent (with '#').
* api_url: slack URL you received when configuring a webhook integration.
* matchers: list of strings for filtering which alerts will be sent.
* `enabled`: whether Alertmanager is deployed or not (default: `true`).
* `domain`: domain name configured in the Ingress (default: `prometheus.apps.${var.cluster_name}.${var.base_domain}`).
* `oidc`: OIDC configuration to be used by OAuth2 Proxy in front of Alertmanager (**required**).
* `deadmanssnitch_url`: url of a Dead Man's Snitch service Alertmanager should report to (by default this reporing is disabled).
* `slack_routes`: list of objects configuring routing of alerts to Slack channels, with the following attributes:
* `name`: name of the configured route.
* `channel`: channel where the alerts will be sent (with '#').
* `api_url`: slack URL you received when configuring a webhook integration.
* `matchers`: list of strings for filtering which alerts will be sent.

|`any`
|`{}`
Expand Down
1 change: 1 addition & 0 deletions docs/modules/ROOT/nav.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@
** xref:ROOT:eks/README.adoc[EKS]
** xref:ROOT:kind/README.adoc[KinD]
** xref:ROOT:sks/README.adoc[SKS]
* https://github.com/camptocamp/devops-stack-module-kube-prometheus-stack[Repository,window=_blank]
* xref:ROOT:ROOT:index.adoc[_Return to DevOps Stack docs_]
57 changes: 37 additions & 20 deletions eks/README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ Description: Override of target revision of the application chart.

Type: `string`

Default: `"v6.0.0"`
Default: `"v6.1.0"`

==== [[input_cluster_issuer]] <<input_cluster_issuer,cluster_issuer>>

Expand Down Expand Up @@ -107,6 +107,15 @@ Type: `bool`

Default: `false`

==== [[input_show_manifest_diff]] <<input_show_manifest_diff,show_manifest_diff>>

Description: A boolean to enable/disable outputting Helm templates on the Terraform plan.
This is useful for debugging purposes only. *Make sure no secrets appear in the Kubernetes manifests before setting this flag, otherwise they will be exposed in your Terraform plan.*

Type: `bool`

Default: `false`

==== [[input_app_autosync]] <<input_app_autosync,app_autosync>>

Description: Automated sync options for the Argo CD Application resource.
Expand Down Expand Up @@ -159,15 +168,15 @@ Default: `{}`

Description: Object containing Alertmanager settings. The following attributes are supported:

* enabled: whether Alertmanager is deployed or not (default: `true`).
* domain: domain name configured in the Ingress (default: `prometheus.apps.${var.cluster_name}.${var.base_domain}`).
* oidc: OIDC configuration to be used by oauth2_proxy in front of Alertmanager (Mandatory).
* deadmanssnitch_url: url of a Dead Man's Snitch service Alertmanager should report to (by default this reporing is disabled).
* slack_routes: list of objects configuring routing of alerts to Slack channels, with the following attributes:
* name: name of the configured route.
* channel: channel where the alerts will be sent (with '#').
* api_url: slack URL you received when configuring a webhook integration.
* matchers: list of strings for filtering which alerts will be sent.
* `enabled`: whether Alertmanager is deployed or not (default: `true`).
* `domain`: domain name configured in the Ingress (default: `prometheus.apps.${var.cluster_name}.${var.base_domain}`).
* `oidc`: OIDC configuration to be used by OAuth2 Proxy in front of Alertmanager (**required**).
* `deadmanssnitch_url`: url of a Dead Man's Snitch service Alertmanager should report to (by default this reporing is disabled).
* `slack_routes`: list of objects configuring routing of alerts to Slack channels, with the following attributes:
* `name`: name of the configured route.
* `channel`: channel where the alerts will be sent (with '#').
* `api_url`: slack URL you received when configuring a webhook integration.
* `matchers`: list of strings for filtering which alerts will be sent.

Type: `any`

Expand Down Expand Up @@ -256,7 +265,7 @@ object({
|[[input_target_revision]] <<input_target_revision,target_revision>>
|Override of target revision of the application chart.
|`string`
|`"v6.0.0"`
|`"v6.1.0"`
|no

|[[input_cluster_issuer]] <<input_cluster_issuer,cluster_issuer>>
Expand All @@ -283,6 +292,14 @@ object({
|`false`
|no

|[[input_show_manifest_diff]] <<input_show_manifest_diff,show_manifest_diff>>
|A boolean to enable/disable outputting Helm templates on the Terraform plan.
This is useful for debugging purposes only. *Make sure no secrets appear in the Kubernetes manifests before setting this flag, otherwise they will be exposed in your Terraform plan.*

|`bool`
|`false`
|no

|[[input_app_autosync]] <<input_app_autosync,app_autosync>>
|Automated sync options for the Argo CD Application resource.
|
Expand Down Expand Up @@ -330,15 +347,15 @@ object({
|[[input_alertmanager]] <<input_alertmanager,alertmanager>>
|Object containing Alertmanager settings. The following attributes are supported:

* enabled: whether Alertmanager is deployed or not (default: `true`).
* domain: domain name configured in the Ingress (default: `prometheus.apps.${var.cluster_name}.${var.base_domain}`).
* oidc: OIDC configuration to be used by oauth2_proxy in front of Alertmanager (Mandatory).
* deadmanssnitch_url: url of a Dead Man's Snitch service Alertmanager should report to (by default this reporing is disabled).
* slack_routes: list of objects configuring routing of alerts to Slack channels, with the following attributes:
* name: name of the configured route.
* channel: channel where the alerts will be sent (with '#').
* api_url: slack URL you received when configuring a webhook integration.
* matchers: list of strings for filtering which alerts will be sent.
* `enabled`: whether Alertmanager is deployed or not (default: `true`).
* `domain`: domain name configured in the Ingress (default: `prometheus.apps.${var.cluster_name}.${var.base_domain}`).
* `oidc`: OIDC configuration to be used by OAuth2 Proxy in front of Alertmanager (**required**).
* `deadmanssnitch_url`: url of a Dead Man's Snitch service Alertmanager should report to (by default this reporing is disabled).
* `slack_routes`: list of objects configuring routing of alerts to Slack channels, with the following attributes:
* `name`: name of the configured route.
* `channel`: channel where the alerts will be sent (with '#').
* `api_url`: slack URL you received when configuring a webhook integration.
* `matchers`: list of strings for filtering which alerts will be sent.

|`any`
|`{}`
Expand Down
Loading

0 comments on commit a31abf3

Please sign in to comment.