Skip to content

Commit

Permalink
feat: added argocd app deployment
Browse files Browse the repository at this point in the history
Signed-off-by: David <davidcalvertfr@gmail.com>
  • Loading branch information
dotdc committed Aug 29, 2022
1 parent 9d11d49 commit 3518826
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 0 deletions.
9 changes: 9 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
- [Installation](#installation)
- [Install manually](#install-manually)
- [Install via grafana.com](#install-via-grafanacom)
- [Install with ArgoCD](#install-with-argocd)
- [Install as ConfigMaps](#install-as-configmaps)
- [Install as ConfigMaps with Terraform](#install-as-configmaps-with-terraform)
- [Contributing](#contributing)
Expand Down Expand Up @@ -80,6 +81,14 @@ Grafana.com dashboard id list:
| k8s-views-nodes.json | 15759 |
| k8s-views-pods.json | 15760 |

### Install with ArgoCD

If you have ArgoCD, this will deploy the dashboards in ArgoCD's default project:

```terminal
kubectl apply -f argocd-app.yml
```

### Install as ConfigMaps

Grafana dashboards can be provisionned as Kubernetes ConfigMaps if you configure the [dashboard sidecar](https://github.com/grafana/helm-charts/blob/main/charts/grafana/values.yaml#L667) available on the official [Grafana Helm Chart](https://github.com/grafana/helm-charts/tree/main/charts/grafana).
Expand Down
29 changes: 29 additions & 0 deletions argocd-app.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: grafana-dashboards-kubernetes
namespace: argocd
labels:
app.kubernetes.io/name: grafana-dashboards-kubernetes
app.kubernetes.io/version: HEAD
app.kubernetes.io/managed-by: argocd
finalizers:
- resources-finalizer.argocd.argoproj.io
spec:
project: default # You may need to change this!
source:
path: ./
repoURL: https://github.com/dotdc/grafana-dashboards-kubernetes
targetRevision: HEAD

destination:
server: https://kubernetes.default.svc
namespace: monitoring
syncPolicy:
## https://argo-cd.readthedocs.io/en/stable/user-guide/auto_sync
automated:
prune: true
selfHeal: true
syncOptions:
- CreateNamespace=true
- Replace=true

0 comments on commit 3518826

Please sign in to comment.