Skip to content

tsemach/go-iotcli

Repository files navigation

  1. go mod init github.com/tsemach/go-gopher-cli
  2. go get -u github.com/spf13/cobra@latest
  3. go install github.com/spf13/cobra-cli@latest
  • cobra-cli installed on ~/go/bin if $GOPATH is not defined
  1. init cobra by: cobra-cli init

  2. get viper package: go get github.com/spf13/viper@v1.8.1

  3. cobra-cli add get

  4. cobra-cli add unit

  5. cobra-cli add install -p unit

  6. go install: this command create an executable in $GOPATH/bin export GOBIN=$GOPATH/bin export PATH=$PATH:$GOBIN

IOT Cli Commands

Environment Variable

  • IOTCLI_ENVIRONMENT - if defined and --env is provide that use it for selecting the environment
  1. iot unit create --env dev | --pid 12345678901 --tid <tls-uuid>
    --pid and --tid are opetional

  2. iot unit install --env dev | --pid 12345678901 --tid <tls-uuid> --data @install.json

  3. iot unit assign --env dev | --pid 12345678901 --tid <tls-uuid> --data @install.json

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages