get

package
v0.78.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 12, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Cmd = &cobra.Command{
	Use:   "get <nodes/shards/...>",
	Short: "Get Nodes/Shards/... from ElasticSearch API",
	Args:  cobra.ExactArgs(1),
	Run: func(c *cobra.Command, args []string) {
		conn := os.Getenv("ELASTICSEARCH_CONNECTION")
		if conn == "" {
			log.Fatalf("ELASTICSEARCH_CONNECTION env var is not set")
		}
		url := conn + "/_cat/" + args[0]
		if FlagVerbose {
			url += "?v"
		}
		exec_utils.ExecHomeOut("curl", url)
	},
}
View Source
var FlagVerbose bool

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL