Skip to content

Navigation Menu

Sign in
Sign up

Latest commit

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

CLIENT-GO EXAMPLES

This repo contains go scripts that illustrate how to use client-go and other
k8s packages in order to call k8s api server programmatically.

Instructions

As an example you can first launch the deployment creation:

❯ go run deployments/create_deployment.go
Deployment created successfully!

and then retrieve the pods metrics:

❯ go run metrics/pods_metrics.go
SHOWING PODS METRICS
pod name: busybox-58d9b8dbdc-b4x27
namespace: test
cpu usage (millicore): 416m
memory usage: 0Mi
pod name: busybox-58d9b8dbdc-glgjt
namespace: test
cpu usage (millicore): 436m
memory usage: 0Mi
pod name: busybox-58d9b8dbdc-wwbrp
namespace: test
cpu usage (millicore): 428m
memory usage: 0Mi

About

client-go examples and use cases 🐝

Topics

Resources

Stars

5 stars

Watchers

0 watching

Forks

Used by

Contributors

Languages

AltStyle γ«γ‚ˆγ£γ¦ε€‰ζ›γ•γ‚ŒγŸγƒšγƒΌγ‚Έ (->γ‚ͺγƒͺγ‚ΈγƒŠγƒ«) /