Skip to content

GitEngHar/elasticsearch-client

Repository files navigation

Hi there! 👋

About this repository

This repository contains a simple Go program for interacting with Elasticsearch on macOS.

Prerequisites

  • Docker
  • Go (≥1.18)

Usage

  1. Start Elasticsearch

    ./elastic-search-run.bash
  2. Generate a password

    ./elastic-search-create-password.bash
  3. Set the environment variable

    export ELASTIC_PASSWD=<YOUR_PASSWORD>
  4. Run the Go program

    go run main.go

Example output

~/Documents/elasticsearch-client git:[master]
go run main.go
Indexed document, status: 200 OK
Found 1 hits:
- bob: Hello Elastic 

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages