You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+3-2Lines changed: 3 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -25,7 +25,7 @@ To explore the complete project documentation, please visit our [documentation s
25
25
26
26
## Getting started
27
27
28
-
To quickstart with a complete workflow and view Amazon EKS infrastructure dashboards,
28
+
To quick start with a complete workflow and view Amazon EKS infrastructure dashboards,
29
29
visit the [Amazon EKS cluster monitoring documentation](https://aws-observability.github.io/terraform-aws-observability-accelerator/eks/)
30
30
31
31
## How it works
@@ -39,8 +39,9 @@ v2+ releases introduces couple of breaking changes compared to previous versions
39
39
40
40
-`modules/workloads/infra` module moves to `modules/eks-monitoring`
41
41
- All EKS configuration options moves from the base module to the `eks-monitoring` module
42
-
- All EKS workload modules `modules/workloads/{java,nginx}` merge into `eks-monitoring` as configuration options (patterns), see [examples](./examples) to provide a more complete visiblity
42
+
- All EKS workload modules `modules/workloads/{java,nginx}` merge into `eks-monitoring` as configuration options (patterns), see [examples](./examples) to provide a more complete visibility
43
43
- All examples have been updated to reflect these changes
44
+
- Introducing GitOps for Grafana contents (Dashboards, Folders and Data sources) with [Grafana Operator](https://github.com/grafana-operator/grafana-operator) and [Flux CD](https://fluxcd.io/)
Copy file name to clipboardExpand all lines: docs/concepts.md
+13Lines changed: 13 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -31,6 +31,19 @@ you need to track changes as part of a Git repository or CI/CD pipeline.
31
31
!!! warning
32
32
When using `tfvars` files, always be careful to not store and commit any secrets (keys, passwords, ...)
33
33
34
+
## Grafana contents via GitOps on Amazon Managed Grafana
35
+
36
+
We have upgraded our solution to use [grafana-operator](https://github.com/grafana-operator/grafana-operator#:~:text=The%20grafana%2Doperator%20is%20a,an%20easy%20and%20scalable%20way.) and [Flux](https://fluxcd.io/) to create Grafana data sources, folder and dashboards via GitOps on Amazon Managed Grafana.
37
+
38
+
The grafana-operator is a Kubernetes operator built to help you manage your Grafana instances inside and outside Kubernetes. Grafana Operator makes it possible for you to manage and create Grafana dashboards, datasources etc. declaratively between multiple instances in an easy and scalable way. Using grafana-operator it will be possible to add AWS data sources such as Amazon Managed Service for Prometheus, Amazon CloudWatch, AWS X-Ray to Amazon Managed Grafana and create Grafana dashboards on Amazon Managed Grafana from your Amazon EKS cluster. This enables us to use our Kubernetes cluster to create and manage the lifecycle of resources in Amazon Managed Grafana in a Kubernetes native way. This ultimately enables us to use GitOps mechanisms using CNCF projects such as Flux to create and manage the lifecycle of resources in Amazon Managed Grafana.
39
+
40
+
GitOps is a way of managing application and infrastructure deployment so that the whole system is described declaratively in a Git repository. It is an operational model that offers you the ability to manage the state of multiple Kubernetes clusters leveraging the best practices of version control, immutable artifacts, and automation. Flux is a declarative, GitOps-based continuous delivery tool that can be integrated into any CI/CD pipeline. It gives users the flexibility of choosing their Git provider (GitHub, GitLab, BitBucket). Now, with grafana-operator supporting the management of external Grafana instances such as Amazon Managed Grafana, operations personas can use GitOps mechanisms using CNCF projects such as Flux to create and manage the lifecycle of resources in Amazon Managed Grafana.
41
+
42
+
We have setup a [GitRepository](https://fluxcd.io/flux/components/source/gitrepositories/) and [Kustomization](https://fluxcd.io/flux/components/kustomize/kustomization/) using flux to sync our GitHub Repository to add Grafana Datasources, folder and Dashboards to Amazon Managed Grafana using Grafana Operator. GitRepository defines a Source to produce an Artifact for a Git repository revision. Kustomization defines a pipeline for fetching, decrypting, building, validating and applying Kustomize overlays or plain Kubernetes manifests. we are also using [Flux Post build variable substitution](https://fluxcd.io/flux/components/kustomize/kustomization/#post-build-variable-substitution) to dynamically render variables such as AMG_AWS_REGION, AMP_ENDPOINT_URL, AMG_ENDPOINT_URL,GRAFANA_NODEEXP_DASH_URL on the YAML manifests during deployment time to avoid hardcoding on the YAML manifests stored in Git repo.
43
+
44
+
We have placed our declarative code snippet to create an Amazon Managed Service For Promethes datasource and Grafana Dashboard in Amazon Managed Grafana in our [AWS Observabiity Accelerator GitHub Repository](https://github.com/aws-observability/aws-observability-accelerator/tree/main/artifacts/grafana-operator-manifests). We have setup a GitRepository to point to the AWS Observabiity Accelerator GitHub Repository and `Kustomization` for flux to sync Git Repository with artifacts in `./artifacts/grafana-operator-manifests` path in the AWS Observabiity Accelerator GitHub Repository. You can use this extension of our solution to point your own Kubernetes manifests to create Grafana Datasources and personified Grafana Dashboards of your choice using GitOps with Grafana Operator and Flux in Kubernetes native way with altering and redeploying this solution for changes to Grafana resources.
Copy file name to clipboardExpand all lines: docs/eks/index.md
+70-7Lines changed: 70 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,7 +14,7 @@ The Amazon EKS infrastructure Terraform modules focuses on metrics collection to
14
14
Managed Service for Prometheus using the [AWS Distro for OpenTelemetry Operator](https://docs.aws.amazon.com/eks/latest/userguide/opentelemetry.html) for Amazon EKS. It deploys the [node exporter](https://github.com/prometheus/node_exporter) and [kube-state-metrics](https://github.com/kubernetes/kube-state-metrics) in your cluster.
15
15
16
16
It provides default dashboards to get a comprehensible visibility on your nodes,
17
-
namespaces, pods, and kubelet operations health. Finally, you get curated Prometheus recording rules
17
+
namespaces, pods, and Kubelet operations health. Finally, you get curated Prometheus recording rules
18
18
and alerts to operate your cluster.
19
19
20
20
Additionally, you can optionally collect custom Prometheus metrics from your applications running
To run this example you need an Amazon Managed Grafana workspace. If you have
75
+
To visualize metrics collected, you need an Amazon Managed Grafana workspace. If you have
76
76
an existing workspace, create an environment variable as described below.
77
-
To create a new workspace, visit our supporting example for Grafana.
77
+
To create a new workspace, visit [our supporting example for Grafana](https://aws-observability.github.io/terraform-aws-observability-accelerator/helpers/managed-grafana/)
78
78
79
79
!!! note
80
80
For the URL `https://g-xyz.grafana-workspace.eu-central-1.amazonaws.com`, the workspace ID would be `g-xyz`
@@ -91,8 +91,14 @@ run the `apply` or `destroy` command.
91
91
92
92
Ensure you have necessary IAM permissions (`CreateWorkspaceApiKey, DeleteWorkspaceApiKey`)
93
93
94
+
!!! note
95
+
Starting version v2.5.x and above, we use Grafana Operator and External Secrets to
96
+
manage Grafana contents. Your API Key will be stored securely on AWS Secrets Manager
97
+
and the Grafana Operator will use it to sync dashboards, folders and data sources.
98
+
Read more [here](https://aws-observability.github.io/terraform-aws-observability-accelerator/concepts/).
Make sure to open the link in the output. After a successful deployment, this will open
111
-
the Prometheus datasource configuration on Grafana.
117
+
the Prometheus data source configuration on Grafana.
112
118
Click `Save & test` and you should see a notification confirming that the Amazon Managed Service for Prometheus workspace is ready to be used on Grafana.
113
119
114
120
```bash
@@ -135,7 +141,7 @@ Open the Amazon Managed Service for Prometheus console and view the details of y
135
141
To setup your alert receiver, with Amazon SNS, follow [this documentation](https://docs.aws.amazon.com/prometheus/latest/userguide/AMP-alertmanager-receiver.html)
136
142
137
143
138
-
## Custom metrics collection
144
+
## Custom Prometheus metrics collection
139
145
140
146
In addition to the cluster metrics, if you are interested in collecting Prometheus
141
147
metrics from your pods, you can use setup `custom metrics collection`.
@@ -170,6 +176,63 @@ sum(up{job="custom-metrics"}) by (container_name, cluster, nodename)
170
176
171
177
## Troubleshooting
172
178
179
+
### 1. Grafana dashboards missing or Grafana API key expired
180
+
181
+
In case you don't see the grafana dashboards in your Amazon Managed Grafana console, check on the logs on your grafana operator pod using the below command :
If you observe, the the above `grafana-api-key error` in the logs, your grafana API key is expired. Please use the operational procedure to update your `grafana-api-key` :
Copy file name to clipboardExpand all lines: docs/index.md
+2-3Lines changed: 2 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -25,9 +25,8 @@ traces collection, dashboards and alerts for monitoring:
25
25
- NGINX workloads (running on Amazon EKS)
26
26
- Java/JMX workloads (running on Amazon EKS)
27
27
- Amazon Managed Service for Prometheus workspaces with Amazon CloudWatch
28
-
- Installs Grafana Operator to add AWS data sources and create Grafana Dashboards to Amazon Managed Grafana.
29
-
- Installs FluxCD to perform GitOps sync of a Git Repo to EKS Cluster. We will use this later for creating Grafana Dashboards and AWS datasources to Amazon Managed Grafana.
30
-
- Installs External Secrets Operator to retrieve and Sync the Grafana API keys.
28
+
-[Grafana Operator](https://github.com/grafana-operator/grafana-operator) and [Flux CD](https://fluxcd.io/) to manage Grafana contents (AWS data sources, Grafana Dashboards) with GitOps
29
+
- External Secrets Operator to retrieve and Sync the Grafana API keys
31
30
32
31
These modules can be directly configured in your existing Terraform
33
32
configurations or ready to be deployed in our packaged
Copy file name to clipboardExpand all lines: examples/eks-cluster-with-vpc/README.md
+1-90Lines changed: 1 addition & 90 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,93 +8,4 @@ This example deploys the following Basic EKS Cluster with VPC
8
8
- Creates Internet gateway for Public Subnets and NAT Gateway for Private Subnets
9
9
- Creates EKS Cluster Control plane with one managed node group
10
10
11
-
## How to Deploy
12
-
13
-
### Prerequisites
14
-
15
-
Ensure that you have installed the following tools in your Mac or Windows Laptop before start working with this module and run Terraform Plan and Apply
Finally, destroy any additional resources that are not in the above modules
97
-
98
-
```sh
99
-
terraform destroy -auto-approve
100
-
```
11
+
You can view the full documentation for this example [here](https://aws-observability.github.io/terraform-aws-observability-accelerator/helpers/new-eks-cluster/)
0 commit comments