- Get the client
go get github.com/satyamz/mayaclient
- You can write
mayacli.go
as given below
package main
import (
"fmt"
"github.com/satyamz/mayaclient" )
func main() {
c := mayaclient.Client{ URL : "http://127.0.0.1:5656/latest/meta-data/instance-id",}
fmt.Println(c.MayaClient())
}
- Run
mayacli.go
usinggo run mayacli.go
orgo build mayacli.go
&./mayacli