splunk-go
is a Splunk REST API Client written in GO designed to allow common tasks for Splunk usage and administration to be conducted through an easy-to-use command line tool. This package assumes that you have a running instance of Splunk Enterprise with user credentials to access this instance. For all information related to the Splunk software, please visit https://www.splunk.com/en_us/software/splunk-enterprise.html
🏠 Homepage
✨ Examples
💻 CLI Docs
# Clone the repository
git clone https://github.com/brittonhayes/splunk-go
# Install dependencies
make dependencies
# From entrypoint
go run main.go --help
# To run with CI
make all
make security
Once the binary is compiled and added to your path, you can utilize the CLI to perform Splunk operations.
- Build the binary
# Build your OS's binary
make build
or
go build -o ./bin/splunk-go main.go
# Cross-compile for all systems
make cross-compile
- Run the help command to get a list of possible actions
# Using the entrypoint
go run main.go --help
or
# Using the Makefile
make run
This will output a message like the following: Help Output
-
Navigate to the
pkg
directory of the repository and add a new*.go
file with your added functionality. -
Run
cobra add [command_name]
and the Cobra CLI tool will add a new*.go
file for your command. -
After creating your command, run
make docs
to automatically update the documentation of all CLI commands.
👤 Britton Hayes
- Github: @brittonhayes
Contributions, issues and feature requests are welcome!
Feel free to check the issues page. You can also take a look at the contributing guide.
Social image from Ashley Mcnamara
Original Project written by drewrm
Give a ⭐️ if this project helped you!
This README was generated with ❤️ by readme-md-generator