Terraform module to deploy grafana on kubernetes.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Christophe van de Kerchove 06c2768088
fix: Force reload when ldap configuration changes
1 month ago
examples/default fix:remove terraformlock files 1 month ago
.gitignore Initial commit 3 months ago
.pre-commit-config.yaml maintenance: add security context for grafana pod 1 month ago
CHANGELOG.md fix: Force reload when ldap configuration changes 1 month ago
Jenkinsfile refactor 2 months ago
LICENSE Initial commit 3 months ago
README.md maintenance: add security context for grafana pod 1 month ago
main.tf fix: Force reload when ldap configuration changes 1 month ago
outputs.tf feat: Allow for a ldap.toml configuration file 1 month ago
variables.tf maintenance: add security context for grafana pod 1 month ago
versions.tf remove providers 1 month ago

README.md

terraform-module-multi-template

Template repository for public terraform modules

Requirements

Name Version
terraform >= 0.13
kubernetes >= 1.10.0
random >= 2.0

Providers

Name Version
kubernetes >= 1.10.0
random >= 2.0

Modules

No Modules.

Resources

Name
kubernetes_config_map
kubernetes_deployment
kubernetes_ingress
kubernetes_persistent_volume_claim
kubernetes_secret
kubernetes_service
kubernetes_service_account
random_string

Inputs

Name Description Type Default Required
additionnal_ingress_paths A list of map of additionnal ingress path to add. Map must support the following structure:
* service_name (optional, string): The name of the kubernates service. (e.g. ssl-redirect)
* service_port (optional, string): The service port number (e.g. use-annotation).
* path (optional, string): The path to the service

For example, see folder examples/without-pvc.
list(any) [] no
annotations Map of annotations that will be merged with all other annotations on all kubernetes resources. map(string) {} no
config_map_annotations Additionnal annotations that will be merged for the config map. map(string) {} no
config_map_labels Additionnal labels that will be merged for the config map. map(string) {} no
config_map_name_prefix Prefix of the config maps that will be created. string "grafana" no
configuration Configuration to use for grafana, all the key pairs will be mounted as env variables not as a file map(string) {} no
deployment_annotations Additionnal labels that will be merged on the deployment. map(string) {} no
deployment_name Name of the deployment that will be create. string "grafana" no
deployment_template_annotations Additionnal annotations that will be merged on the deployment. map(string) {} no
deployment_template_labels Map of annotations to apply to the namespace. map(string) {} no
deploymnet_labels deploymnet labels that will be merged for the deployment. map(string) {} no
enabled_localstorage should local storage be enabled for grafana bool true no
enabled_security_context should security contect be enabled for grafana pods bool false no
image Image to use. string "grafana/grafana" no
image_version Version of the image to use. string "latest" no
ingress_annotations Map of annotations that will be applied on the ingress. map(string) {} no
ingress_enabled Whether or not to enable the ingress. bool true no
ingress_host Host on which the ingress wil be available (ex: grafana.example.com). string "grafana.example.com" no
ingress_labels Map of labels that will be applied on the ingress. map(string) {} no
ingress_name Name of the ingress. string "grafana" no
ingress_tls_enabled Whether or not TLS should be enabled on the ingress. bool true no
ingress_tls_secret_name Name of the secret to use to put TLS on the ingress. string "grafana" no
labels Map of labels that will be merged with all other labels on all kubernetes resource. map(string) {} no
ldap_configuration Content of the ldap.toml file that will be used for ldap configuration. (LDAP needs to be enabled in the configuration to take effect.) string "" no
namespace Namespace in which the module will be deployed. string "grafana" no
pvc_access_modes A set of the desired access modes the volume should have. list(string)
[
“ReadWriteOnce"
]
no
pvc_annotations Map of annotations that will be applied on the ingress. map(string) {} no
pvc_labels Map of labels that will be applied on the ingress. map(string) {} no
pvc_name Name of the PVC for gradfana string "grafana" no
pvc_storage storage required for pvc string "10Gi" no
pvc_storage_class_name Name of the storage class that will be applied to persistent volume claim. string null no
pvc_volume_name Name of the volume bound to the persistent volume claim. string "" no
pvc_wait_until_bound Whether to wait for the claim to reach Bound state (to find volume in which to claim the space) bool false no
replicas Number of replicas to deploy. number 1 no
resources_limits_cpu Amount of cpu time that the application limits. string "500m" no
resources_limits_memory Amount of memory that the application limits. string "512Mi" no
resources_requests_cpu Amount of cpu time that the application requests. string "100m" no
resources_requests_memory Amount of memory that the application requests. string "256Mi" no
secret_annotations Additionnal annotations that will be merged for the secret. map(string) {} no
secret_configuration should contain grafana secret env variables, see the example below
For example, {
{ “GF_SECURITY_ADMIN_PASSWORD” = “xxxxx” }
}
map(string) {} no
secret_labels Additionnal labels that will be merged for the secret. map(string) {} no
secret_name Name of the secret that will be created. string "grafana" no
security_context_fs_group when fsGroup field is specified, all processes of the container are also part of the supplementary group ID given string "2000" no
service_account_annotations Map of annotations that is merged on the service account. map(string) {} no
service_account_labels Map of labels that is merged on the service account. map(string) {} no
service_account_name name of the service account string "grafana" no
service_annotations Map of annotations that will be applied on the service. map(string) {} no
service_labels Map of labels that will be applied on the service. map(string) {} no
service_name Name of the service. string "grafana" no
service_type type of service string "ClusterIP" no

Outputs

Name Description
deployment n/a
environment_config_map n/a
files_config_map n/a
ingress n/a
secret n/a
service n/a
service_account n/a

Versioning

This repository follows Semantic Versioning 2.0.0

Git Hooks

This repository uses pre-commit hooks.