docker-compose Elasticsearch Generator
Generate a ready-to-use docker-compose for single-node Elasticsearch, with memory and volume configured. Spin up your local search engine with one command.
YAML
—
Elasticsearch in a container for development
Bringing up a local Elasticsearch for development usually stalls on two things: it tries to form a cluster and sits waiting for other nodes, and it refuses to start because of the security layer enabled by default in recent versions. Both are solved with environment variables, and that is what separates a file that comes up in seconds from an afternoon of trial and error.
Enter the version and the page assembles the service with both options: single-node discovery, which makes Elasticsearch stop looking for companions and elect itself, and disabling the security layer, which removes the password and certificate requirement. The API port is exposed so the application can reach it.
This configuration is explicitly for development and should stay nowhere near production — with no authentication, anyone on the network can read and delete indices. It is also worth knowing about the system's virtual memory limit: Elasticsearch requires a minimum number of memory map areas that several Linux installations do not have by default, and the symptom is the container dying right after startup with a message about that limit.
Frequently asked questions
Why does it die right after starting?
How do I limit the memory it uses?
Do I need a dashboard alongside?
Related Tools
docker-compose MySQL Generator
Generates a ready-to-use docker-compose for MySQL, with the root password, port 3306 published and a persistent volume. Pick the image tag and start the database.
docker-compose Redis Generator
Generates a ready-to-use docker-compose for Redis, publishing port 6379 with a persistent volume. Pick the image tag and spin up your local cache or broker with one command.
docker-compose PostgreSQL Generator
Generate a ready-to-use docker-compose for PostgreSQL, with user, password, database and a persistent volume set up. Spin up your local DB with one command.
docker-compose MongoDB Generator
Generates a ready-to-use docker-compose for MongoDB, with root user and password, port 27017 published and a persistent volume. You create the database after it starts.
docker-compose RabbitMQ Generator
Generate a ready-to-use docker-compose for RabbitMQ with the management UI enabled, user, password and ports. Spin up your local message broker instantly.
Docker Run → Compose
Convert a docker run command to the equivalent docker-compose.yml automatically. Maps ports, volumes, environment variables, networks and restart policies.