func NewClient(c Config) (*api.Client, error) {
	nomadDefaultConfig := api.DefaultConfig()
	envAddress := os.Getenv("NOMAD_ADDRESS")

	if envAddress != "" {
		nomadDefaultConfig.Address = envAddress
	} else {
		nomadDefaultConfig.Address = c.Address
	}

	client, err := api.NewClient(nomadDefaultConfig)
	if err != nil {
		return nil, err
	}

	return client, nil
}
// NewClient will create a instance of a nomad API Client
NewClient will create a instance of a nomad API Client
// NewClient will create a instance of a nomad API Client
func NewClient(c Config) (*api.Client, error) {
	nomadDefaultConfig := api.DefaultConfig()
	envAddress := os.Getenv("NOMAD_ADDRESS")
	if envAddress != "" {
		nomadDefaultConfig.Address = envAddress
	} else {
		nomadDefaultConfig.Address = c.Address
	}
	client, err := api.NewClient(nomadDefaultConfig)
	if err != nil {
		return nil, err
	}
	return client, nil
}
func NewClient ( c Config ) ( * api . Client , error ) { nomadDefaultConfig := api . DefaultConfig ( ) envAddress := os . Getenv ( " " ) if envAddress != " " { nomadDefaultConfig . Address = envAddress } else { nomadDefaultConfig . Address = c . Address } client , err := api . NewClient ( nomadDefaultConfig ) if err != nil { return nil , err } return client , nil }
NewClient will create a instance of a nomad API Client
NewClient will create a instance of a nomad API Client