Go Notes
From Federal Burro of Information
NumCPU()
How many cpu's does my pod see?
kubectl exec -it $pod -- /bin/bash apt-get update apt-get install golang
tmp.go
package main import "fmt" import "runtime" func main() { var i interface{} = runtime.NumCPU() fmt.Printf("%v\n", i) fmt.Println("hello world") }
go run tmp.go
16 hello world