Skip to content

Instantly share code, notes, and snippets.

Avatar

Ram Iyengar ramiyengar

  • Cloud Foundry Foundation
  • The World
  • Twitter @ramiyengar
View GitHub Profile
View gist:8e4428f62f3aff13e54bcba12352d977
./hack/generate-values.sh -d padarekha.com /home/ram/cf-values.yml
View cf-for-k8s-prometheus-tree
cf-k8s-prometheus/
|-- LICENSE
|-- NOTICE
|-- README.md
|-- config
| |-- add-prometheus-node-exporter.yml
| `-- add-prometheus-server.yml
|-- experimental
|-- add-grafana.yml
`-- add-prometheus-pushgateway.yml
View ytt-cf-k8s-prometheus
ytt -f /home/ram/cf-for-k8s/config -f /home/ram/cf-k8s-prometheus/config -f /home/ram/tempdir/cf-values.yml > /home/ram/tempdir/cf-for-k8s-rendered.yml
View kapp-cf-k8s-prometheus
kapp deploy -a cf -f /home/ram/tempdir/cf-for-k8s-rendered.yml -y
View kubectl-patch-cf-k8s
kubectl patch svc istio-ingressgateway --namespace istio-system --patch '{"spec": { "loadBalancerIP": "<insert-static-ip-here>" }}'
View kubectl-get-pods-cf-k8s-prometheus
kubectl get pods -n cf-system
NAME READY STATUS RESTARTS AGE
ccdb-migrate-x9mfb 0/2 Completed 0 9h
cf-api-clock-6cb5ff6478-vkmjt 2/2 Running 0 9h
cf-api-controllers-6bbc6f7484-cstlr 3/3 Running 0 9h
cf-api-deployment-updater-7f48449c5c-5xlhb 2/2 Running 2 9h
cf-api-server-78679fcff4-25pw5 6/6 Running 0 9h
cf-api-worker-757d656c4-4fn2f 3/3 Running 0 9h
eirini-77bc57bd74-9qn64 2/2 Running 0 9h
eirini-controller-648645bcf8-r72fz 2/2 Running 0 9h
View git-clone
git clone https://github.com/cloudfoundry/cf-for-k8s-metric-examples.git
View manifest.yml-cf-test-metrics
metadata:
annotations:
prometheus.io/scrape: "true"
prometheus.io/port: "2112"
prometheus.io/path: "/metrics"
View kubetl-get-pods-cf-workloads
kubectl get pods -n cf-workloads
NAME READY STATUS RESTARTS AGE
go-app-with-metrics-devel-cf3200ae74-0 2/2 Running 0 4h38m
go-app-with-metrics-devel-cf3200ae74-1 2/2 Running 0 4h38m
restart-workloads-for-istio1-7-3-r6cxp 0/1 Completed 0 9h