{"id":15044315,"url":"https://github.com/elastic/start-local","last_synced_at":"2025-04-05T14:03:32.218Z","repository":{"id":256356325,"uuid":"855026084","full_name":"elastic/start-local","owner":"elastic","description":"Try Elasticsearch and Kibana locally","archived":false,"fork":false,"pushed_at":"2025-03-28T08:14:06.000Z","size":177,"stargazers_count":112,"open_issues_count":2,"forks_count":26,"subscribers_count":165,"default_branch":"main","last_synced_at":"2025-03-29T13:04:28.799Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/elastic.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-09-10T07:12:45.000Z","updated_at":"2025-03-29T10:23:03.000Z","dependencies_parsed_at":"2024-10-28T09:36:37.527Z","dependency_job_id":"b359e691-9c0b-4516-9462-0c1c42b9ca2f","html_url":"https://github.com/elastic/start-local","commit_stats":{"total_commits":11,"total_committers":2,"mean_commits":5.5,"dds":0.09090909090909094,"last_synced_commit":"960248a5e78f85abe00f2d4d15fb1fe2b95ccc57"},"previous_names":["elastic/start-local"],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elastic%2Fstart-local","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elastic%2Fstart-local/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elastic%2Fstart-local/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elastic%2Fstart-local/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/elastic","download_url":"https://codeload.github.com/elastic/start-local/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247345849,"owners_count":20924102,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-09-24T20:50:26.315Z","updated_at":"2025-04-05T14:03:32.195Z","avatar_url":"https://github.com/elastic.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🚀 Try Elasticsearch and Kibana locally\n\nRun Elasticsearch and Kibana on your local machine using a simple shell script. This setup uses [Docker](https://www.docker.com/) behind the scenes to install and run the services.\n\n\u003e [!IMPORTANT]  \n\u003e This script is for local testing only. Do not use it in production!\n\u003e For production installations refer to the official documentation for [Elasticsearch](https://www.elastic.co/downloads/elasticsearch) and [Kibana](https://www.elastic.co/downloads/kibana).\n\n## 🌟 Features\n\nThis script comes with a one-month trial license.\nAfter the trial period, the license reverts to [Free and open - Basic](https://www.elastic.co/subscriptions).\n\n- **Trial**: Includes **All** features like the [Playground](https://www.elastic.co/docs/current/serverless/elasticsearch/playground), [ELSER](https://www.elastic.co/guide/en/machine-learning/current/ml-nlp-elser.html), [semantic retrieval model](https://www.elastic.co/guide/en/machine-learning/8.15/ml-nlp-text-emb-vector-search-example.html), the [Elastic Inference API](https://www.elastic.co/guide/en/elasticsearch/reference/current/inference-apis.html) and much more.\n- **Free and open - Basic**: Includes features like [vector search](https://www.elastic.co/what-is/vector-search), [ES|QL](https://www.elastic.co/guide/en/elasticsearch/reference/current/esql.html) and much more.\n\nFor a complete list of subscriptions and features, see our [subscriptions page](https://www.elastic.co/subscriptions).\n\n## 💻 System requirements\n\n- 5 GB of available disk space\n- [Docker](https://www.docker.com/)\n- Works on Linux and macOS\n- On Microsoft Windows it works using [Windows Subsystem for Linux (WSL)](https://learn.microsoft.com/en-us/windows/wsl/install)\n\n## 🏃‍♀️‍➡️ Getting started\n\n### Setup\n\nRun the `start-local` script using [curl](https://curl.se/):\n\n```bash\ncurl -fsSL https://elastic.co/start-local | sh\n```\n\nThis script creates an `elastic-start-local` folder containing:\n\n- `docker-compose.yml`: Docker Compose configuration for Elasticsearch and Kibana\n- `.env`: Environment settings, including the Elasticsearch password\n- `start.sh` and `stop.sh`: Scripts to start and stop Elasticsearch and Kibana\n- `uninstall.sh`: The script to uninstall Elasticsearch and Kibana\n\n### Select the version to install\n\nBy default, `start-local` uses the latest stable version of Elastic Stack. If you want, you can specify\na different version using the `-v` parameter, as follows:\n\n```bash\ncurl -fsSL https://elastic.co/start-local | sh -s -- -v 8.16.0\n```\n\nThe previous command installs Elasticsearch and Kibana `8.16.0`.\n\nUsing the `-v` parameter, you can also install beta releases, this can be useful for testing an\nupcoming release. For instance, you can install the `9.0.0-beta1` using the following\ncommand:\n\n```bash\ncurl -fsSL https://elastic.co/start-local | sh -s -- -v 9.0.0-beta1\n```\n\nThe `9.0.0-beta1` version was released on February 18, 2025.\n\n### Install only Elasticsearch\n\nIf you want to install only Elasticsearch, without Kibana, you can use the `-esonly` option\nas follows:\n\n```bash\ncurl -fsSL https://elastic.co/start-local | sh -s -- -esonly\n```\n\nThis command can be useful if you don't have enough resources and want to test only Elasticsearch.\n\n### 🌐 Endpoints\n\nAfter running the script:\n\n- Elasticsearch will be running at \u003chttp://localhost:9200\u003e\n- Kibana will be running at \u003chttp://localhost:5601\u003e\n\nThe script generates a random password for the `elastic` user, displayed at the end of the installation and stored in the `.env` file.\n\n\u003e [!CAUTION]\n\u003e HTTPS is disabled, and Basic authentication is used for Elasticsearch. This configuration is for local testing only. For security, Elasticsearch and Kibana are accessible only via `localhost`.\n\n### 🔑 API key\n\nAn API key for Elasticsearch is generated and stored in the `.env` file as `ES_LOCAL_API_KEY`. Use this key to connect to Elasticsearch with the [Elastic SDK](https://www.elastic.co/guide/en/elasticsearch/client) or [REST API](https://www.elastic.co/guide/en/elasticsearch/reference/current/rest-apis.html).\n\nCheck the connection to Elasticsearch using `curl` in the `elastic-start-local` folder:\n\n```bash\nsource .env\ncurl $ES_LOCAL_URL -H \"Authorization: ApiKey ${ES_LOCAL_API_KEY}\"\n```\n\n## 🐳 Start and stop the services\n\nYou can use the `start` and `stop` commands available in the `elastic-start-local` folder.\n\nTo **stop** the Elasticsearch and Kibana Docker services, use the `stop` command:\n\n```bash\ncd elastic-start-local\n./stop.sh\n```\n\nTo **start** the Elasticsearch and Kibana Docker services, use the `start` command:\n\n```bash\ncd elastic-start-local\n./start.sh\n```\n\n[Docker Compose](https://docs.docker.com/reference/cli/docker/compose/).\n\n## 🗑️ Uninstallation\n\nTo remove the `start-local` installation:\n\n```bash\ncd elastic-start-local\n./uninstall.sh\n```\n\n\u003e [!WARNING]  \n\u003e This erases all data permanently.\n\n## 📝 Logging\n\nIf the installation fails, an error log is created in `error-start-local.log`. This file contains logs from Elasticsearch and Kibana, captured using the [docker logs](https://docs.docker.com/reference/cli/docker/container/logs/) command.\n\n## ⚙️ Customizing settings\n\nTo change settings (e.g., Elasticsearch password), edit the `.env` file. Example contents:\n\n```bash\nES_LOCAL_VERSION=8.15.2\nES_LOCAL_URL=http://localhost:9200\nES_LOCAL_CONTAINER_NAME=es-local-dev\nES_LOCAL_DOCKER_NETWORK=elastic-net\nES_LOCAL_PASSWORD=hOalVFrN\nES_LOCAL_PORT=9200\nKIBANA_LOCAL_CONTAINER_NAME=kibana-local-dev\nKIBANA_LOCAL_PORT=5601\nKIBANA_LOCAL_PASSWORD=YJFbhLJL\nES_LOCAL_API_KEY=df34grtk...==\n```\n\n\u003e [!IMPORTANT]\n\u003e After changing the `.env` file, restart the services using `stop` and `start`:\n\u003e\n\u003e ```bash\n\u003e cd elastic-start-local\n\u003e ./stop.sh\n\u003e ./start.sh\n\u003e ```\n\n## 🧪 Testing the installer\n\nWe use [bashunit](https://bashunit.typeddevs.com/) to test the script. Tests are in the `/tests` folder.\n\n### Running tests\n\n1. Install bashunit:\n\n   ```bash\n   curl -s https://bashunit.typeddevs.com/install.sh | bash\n   ```\n\n2. Run tests:\n\n   ```bash\n   lib/bashunit\n   ```\n\nThe tests run `start-local.sh` and check if Elasticsearch and Kibana are working.\n\n\u003e [!NOTE]\n\u003e For URL pipeline testing, a local web server is used. This requires [PHP](https://www.php.net/).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felastic%2Fstart-local","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Felastic%2Fstart-local","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felastic%2Fstart-local/lists"}