You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Suitable for Demoing, MVPs and small production deployments.
38
35
39
-
Stack Version: [8.10.2](https://www.elastic.co/blog/whats-new-elastic-8-10-0) 🎉 - Based on [Official Elastic Docker Images](https://www.docker.elastic.co/)
40
-
> You can change Elastic Stack version by setting `ELK_VERSION` in `.env` file and rebuild your images. Any version >= 8.0.0 is compatible with this template.
36
+
Stack Version: [9.2.3](https://www.elastic.co/guide/en/elasticsearch/reference/9.2/release-notes-9.2.3.html) 🎉 - Based on [Official Elastic Docker Images](https://www.docker.elastic.co/)
37
+
> You can change Elastic Stack version by setting `ELK_VERSION` in `.env` file and rebuild your images. Any version >= 9.0.0 is compatible with this template.
38
+
>
39
+
> ⚠️ **Upgrading from 8.x?** See the [Upgrade Notes](#upgrade-notes-from-8x-to-9x) section below for breaking changes and migration steps.
- SIEM (Security information and event management).
54
54
- Enabling Trial License
55
-
- Use Docker-Compose and `.env` to configure your entire stack parameters.
55
+
- Use DockerCompose and `.env` to configure your entire stack parameters.
56
56
- Persist Elasticsearch's Keystore and SSL Certifications.
57
-
- Self-Monitoring Metrics Enabled.
57
+
- Self-Monitoring Metrics Enabled (using Metricbeat for ES 9+).
58
58
- Prometheus Exporters for Stack Metrics.
59
59
- Embedded Container Healthchecks for Stack Images.
60
60
@@ -79,7 +79,7 @@ Elastdocker differs from `deviantony/docker-elk` in the following points.
79
79
80
80
- Parameterize all other Config like Heap Size.
81
81
82
-
- Add recommended environment configurations as Ulimits and Swap disable to the docker-compose.
82
+
- Add recommended environment configurations as Ulimits and Swap disable to Docker Compose.
83
83
84
84
- Make it ready to be extended into a multinode cluster.
85
85
@@ -92,12 +92,23 @@ Elastdocker differs from `deviantony/docker-elk` in the following points.
92
92
</p>
93
93
</details>
94
94
95
+
96
+
### Automatic Docker Container Log Collection
97
+
98
+
Collect logs from **all Docker containers** on your host with a single command:
99
+
100
+
```bash
101
+
make collect-docker-logs
102
+
```
103
+
104
+
Filebeat automatically discovers containers, parses logs, and ships them to Elasticsearch. View and analyze everything in Kibana with zero configuration.
105
+
106
+
95
107
-----
96
108
97
109
# Requirements
98
110
99
-
-[Docker 20.05 or higher](https://docs.docker.com/install/)
100
-
-[Docker-Compose 1.29 or higher](https://docs.docker.com/compose/install/)
111
+
-[Docker 20.05 or higher](https://docs.docker.com/install/) with Docker Compose v2
101
112
- 4GB RAM (For Windows and MacOS make sure Docker's VM has more than 4GB+ memory.)
102
113
103
114
# Setup
@@ -113,7 +124,7 @@ Elastdocker differs from `deviantony/docker-elk` in the following points.
113
124
>**For Linux's docker hosts only**. By default virtual memory [is not enough](https://www.elastic.co/guide/en/elasticsearch/reference/current/vm-max-map-count.html) so run the next command as root `sysctl -w vm.max_map_count=262144`
114
125
3. Start Elastic Stack
115
126
```bash
116
-
$ make elk <OR> $ docker-compose up -d <OR> $ docker compose up -d
127
+
$ make elk <OR> $ docker compose up -d
117
128
```
118
129
4. Visit Kibana at [https://localhost:5601](https://localhost:5601) or `https://<your_public_ip>:5601`
119
130
@@ -168,14 +179,15 @@ $ make prune
168
179
169
180
* Some Configuration are parameterized in the `.env` file.
170
181
*`ELASTIC_PASSWORD`, user `elastic`'s password (default: `changeme`_pls_).
171
-
*`ELK_VERSION` Elastic Stack Version (default: `8.10.2`)
182
+
*`ELK_VERSION` Elastic Stack Version (default: `9.2.3`)
172
183
*`ELASTICSEARCH_HEAP`, how much Elasticsearch allocate from memory (default: 1GB -good for development only-)
173
184
*`LOGSTASH_HEAP`, how much Logstash allocate from memory.
174
185
* Other configurations which their such as cluster name, and node name, etc.
175
186
* Elasticsearch Configuration in `elasticsearch.yml` at `./elasticsearch/config`.
176
187
* Logstash Configuration in `logstash.yml` at `./logstash/config/logstash.yml`.
177
188
* Logstash Pipeline in `main.conf` at `./logstash/pipeline/main.conf`.
178
189
* Kibana Configuration in `kibana.yml` at `./kibana/config`.
190
+
* Metricbeat Configuration in `metricbeat.yml` at `./metricbeat/config` (for Stack Monitoring in ES 9+).
179
191
180
192
### Setting Up Keystore
181
193
@@ -193,7 +205,7 @@ make keystore
193
205
194
206
- Adding Two Extra Nodes to the cluster will make the cluster depending on them and won't start without them again.
195
207
196
-
- Makefile is a wrapper around `Docker-Compose` commands, use `make help` to know every command.
208
+
- Makefile is a wrapper around `DockerCompose` commands, use `make help` to know every command.
197
209
198
210
- Elasticsearch will save its data to a volume named `elasticsearch-data`
199
211
@@ -243,13 +255,19 @@ For more details or other languages you can check the following:
243
255
244
256
# Monitoring The Cluster
245
257
246
-
### Via Self-Monitoring
258
+
### Via Stack Monitoring (Metricbeat)
259
+
260
+
**Elasticsearch 9+** uses Metricbeat for Stack Monitoring (the recommended approach). When you start monitoring with `make monitoring`, Metricbeat will collect metrics from all stack components and send them to Elasticsearch.
247
261
248
-
Head to Stack Monitoring tab in Kibana to see cluster metrics for all stack components.
262
+
Head to **Stack Monitoring** tab in Kibana to see cluster metrics for all stack components.
- `metricbeat/config/metricbeat.yml` - **NEW FILE** for Stack Monitoring
322
+
323
+
### 3. **Filebeat Migration to Filestream Input**
324
+
325
+
The `container` input type is deprecated in Filebeat 9. Migrated to the modern `filestream` input with container parser - the ES 9+ recommended approach.
326
+
327
+
**Files Modified:**
328
+
- `filebeat/filebeat.docker.logs.yml` - Now uses `type: filestream` with container parser
329
+
- `filebeat/filebeat.monitoring.yml` - All module inputs migrated to filestream
330
+
331
+
**Key Changes:**
332
+
- `type: container` → `type: filestream` with unique IDs
333
+
- Added `parsers.container` configuration for Docker log parsing
334
+
- Added `prospector.scanner.symlinks: true` for Docker log paths
335
+
- No deprecation warnings - fully ES 9 compliant
336
+
337
+
### 4. **Certificate Generation Script**
338
+
339
+
**File: `setup/setup-certs.sh`**
340
+
- Updated password generation to work without `openssl` command (not available in ES 9 containers)
341
+
- Now uses `/dev/urandom` for random password generation
342
+
343
+
### 5. **Elasticsearch Exporter Flags**
344
+
345
+
**File: `docker-compose.monitor.yml`**
346
+
- Updated exporter flags for compatibility with exporter v1.10.0+
347
+
- `--collector.indices` → `--es.indices`
348
+
349
+
## Known Deprecation Warnings
350
+
351
+
The following deprecation warnings are expected and originate from upstream Elastic components. They will be resolved in future component releases:
352
+
353
+
1. **Beats using `?local` parameter** (CRITICAL) - ~446 occurrences
354
+
- Source: Metricbeat
355
+
- Will be fixed in future Beats releases
356
+
- **Note:** Filebeat no longer generates these warnings after migrating to filestream input
0 commit comments