-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Adds prometheus and grafana stack for monitoring
- Loading branch information
1 parent
db849f9
commit 68f2072
Showing
10 changed files
with
107 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Monitoring Stack | ||
|
||
UnderStack uses the `kube-prometheus-stack` which is a prometheus + grafana monitoring stack | ||
|
||
<https://github.com/prometheus-operator/kube-prometheus> | ||
|
||
It uses the namespace: `monitoring` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# kube-prometheus-stack for monitoring | ||
|
||
Read more in the docs: <https://rackerlabs.github.io/understack/user-guide/monitoring/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
--- | ||
apiVersion: external-secrets.io/v1beta1 | ||
kind: ExternalSecret | ||
metadata: | ||
name: grafana-sso | ||
spec: | ||
refreshInterval: 1h | ||
secretStoreRef: | ||
kind: ClusterSecretStore | ||
name: dex | ||
target: | ||
name: grafana-sso | ||
creationPolicy: Owner | ||
deletionPolicy: Delete | ||
dataFrom: | ||
- extract: | ||
key: grafana-sso | ||
conversionStrategy: Default | ||
decodingStrategy: None | ||
metadataPolicy: None |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
grafana: | ||
envValueFrom: | ||
GF_AUTH_GENERIC_OAUTH_CLIENT_ID: | ||
secretKeyRef: | ||
name: grafana-sso | ||
key: client-id | ||
GF_AUTH_GENERIC_OAUTH_CLIENT_SECRET: | ||
secretKeyRef: | ||
name: grafana-sso | ||
key: client-secret | ||
GF_AUTH_GENERIC_OAUTH_ISSUER: | ||
secretKeyRef: | ||
name: grafana-sso | ||
key: issuer | ||
grafana.ini: | ||
auth.generic_oauth: | ||
name: Dex | ||
enabled: true | ||
client_id: $__env{GF_AUTH_GENERIC_OAUTH_CLIENT_ID} | ||
client_secret: $__env{GF_AUTH_GENERIC_OAUTH_CLIENT_SECRET} | ||
scopes: openid email profile groups offline_access | ||
auth_url: $__env{GF_AUTH_GENERIC_OAUTH_ISSUER}/auth | ||
token_url: $__env{GF_AUTH_GENERIC_OAUTH_ISSUER}/token | ||
api_url: $__env{GF_AUTH_GENERIC_OAUTH_ISSUER}/userinfo | ||
server: | ||
root_url: https://%(domain)s | ||
|
||
ingress: | ||
enabled: true | ||
ingressClassName: "nginx" | ||
hosts: | ||
- grafana.${DNS_ZONE} | ||
tls: | ||
- hosts: | ||
- grafana.${DNS_ZONE} | ||
secretName: grafana-ingress-tls | ||
annotations: | ||
nginx.ingress.kubernetes.io/rewrite-target: / | ||
cert-manager.io/cluster-issuer: ${DEPLOY_NAME}-cluster-issuer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters