Skip to content

Commit 1a349b5

Browse files
committed
Notes for grafana
1 parent 2ec48b2 commit 1a349b5

File tree

1 file changed

+21
-3
lines changed

1 file changed

+21
-3
lines changed

docs/tutorials/setup_k8s.md

Lines changed: 21 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -208,9 +208,9 @@ kubectl create namespace argocd
208208
kubectl apply -n argocd -f https://raw.githubusercontent.com/argoproj/argo-cd/stable/manifests/install.yaml
209209
```
210210

211-
To access the gui through a browser on `https://localhost:8080/`:
211+
To access the gui through a browser on `https://localhost:8081/`:
212212
```
213-
kubectl port-forward svc/argocd-server -n argocd 8080:443
213+
kubectl port-forward svc/argocd-server -n argocd 8081:443
214214
```
215215

216216
The user is `admin` and the password can be retrived using:
@@ -227,13 +227,31 @@ rm argocd-linux-amd64
227227

228228
Create a new argocd project from the command line, with permissions to deploy into your namespace:
229229
```
230-
argocd login localhost:8080
230+
argocd login localhost:8081
231231
argocd proj create t03 -d https://kubernetes.default.svc,t03-beamline -d https://kubernetes.default.svc,argocd -s "*"
232232
```
233233

234234
When deploying to the same cluster that Argo CD is running in the destination cluster is by default aliased as "in-cluster".
235235
Argocd Apps should be deployed into the argocd namespace.
236236

237+
### Set up kube-prometheus-stack (Optional)
238+
239+
Prometheus + Grafana + Alertmanager is a common stack used for cluster monitoring. The "kube-prometheus-stack" Helm chart already has Prometheus configured to scrape the cluster and Grafana comes with some prebuilt dashboards to visualize the data.
240+
241+
As per <https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack> it can be installed into the cluster as follows:
242+
```
243+
helm repo add prometheus-community https://prometheus-community.github.io/helm-charts
244+
helm repo update
245+
helm install kube-prometheus-stack prometheus-community/kube-prometheus-stack --create-namespace --namespace monitoring --set kube-state-metrics.extraArgs="{--metric-labels-allowlist=pods=[*]}"
246+
```
247+
248+
To access the Grafana gui through a browser on `https://localhost:3000/`:
249+
```
250+
kubectl port-forward svc/kube-prometheus-stack-grafana -n monitoring 3000:80
251+
```
252+
The user is `admin` and the password is `prom-operator`
253+
254+
237255
### Completed
238256

239257
That's it. You now have installed the necessary software to start experimenting with IOCs on Kubernetes.

0 commit comments

Comments
 (0)