Skip to content

Commit 75e3157

Browse files
committed
Add Elk Stack to Cantabular Import
1 parent 672ea74 commit 75e3157

File tree

5 files changed

+55
-2
lines changed

5 files changed

+55
-2
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,5 @@ cantabular-import/analysis/count-log-events/*.txt
1313
cantabular-import/analysis/tmp/*.txt
1414

1515
cantabular-import/analysis/simple-plot/*.svg
16+
17+
cantabular-import/elk/elasticsearch_data/*

cantabular-import/.env

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
COMPOSE_FILE=deps.yml:dp-import-api.yml:dp-import-cantabular-dataset.yml:dp-import-cantabular-dimension-options.yml:dp-cantabular-server.yml:dp-cantabular-api-ext.yml:dp-dataset-api.yml:dp-cantabular-csv-exporter.yml:dp-cantabular-dimension-api.yml:dp-cantabular-filter-flex-api.yml:dp-cantabular-metadata-service.yml:dp-cantabular-metadata-exporter.yml:dp-cantabular-xlsx-exporter.yml:dp-recipe-api.yml:dp-filter-api.yml:zebedee.yml:dp-download-service.yml:dp-frontend-dataset-controller.yml:dp-api-router.yml:dp-frontend-router.yml:dp-publishing-dataset-controller.yml:florence.yml:the-train.yml:babbage.yml:dp-frontend-filter-flex-dataset.yml:dp-population-types-api.yml
1+
COMPOSE_FILE=elk.yml:deps.yml:dp-import-api.yml:dp-import-cantabular-dataset.yml:dp-import-cantabular-dimension-options.yml:dp-cantabular-server.yml:dp-cantabular-api-ext.yml:dp-dataset-api.yml:dp-cantabular-csv-exporter.yml:dp-cantabular-dimension-api.yml:dp-cantabular-filter-flex-api.yml:dp-cantabular-metadata-service.yml:dp-cantabular-metadata-exporter.yml:dp-cantabular-xlsx-exporter.yml:dp-recipe-api.yml:dp-filter-api.yml:zebedee.yml:dp-download-service.yml:dp-frontend-dataset-controller.yml:dp-api-router.yml:dp-frontend-router.yml:dp-publishing-dataset-controller.yml:florence.yml:the-train.yml:babbage.yml:dp-frontend-filter-flex-dataset.yml:dp-population-types-api.yml
22
COMPOSE_PATH_SEPARATOR=:
33
COMPOSE_PROJECT_NAME=cantabular-import-journey

cantabular-import/.env.backend

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
COMPOSE_FILE=deps.yml:dp-import-api.yml:dp-import-cantabular-dataset.yml:dp-import-cantabular-dimension-options.yml:dp-cantabular-server.yml:dp-cantabular-api-ext.yml:dp-dataset-api.yml:dp-cantabular-csv-exporter.yml:dp-cantabular-dimension-api.yml:dp-filter-api.yml:dp-cantabular-filter-flex-api.yml:dp-cantabular-metadata-service.yml:dp-cantabular-metadata-exporter.yml:dp-cantabular-xlsx-exporter.yml:dp-recipe-api.yml:zebedee.yml:dp-download-service.yml:dp-population-types-api.yml
1+
COMPOSE_FILE=elk.yml:deps.yml:dp-import-api.yml:dp-import-cantabular-dataset.yml:dp-import-cantabular-dimension-options.yml:dp-cantabular-server.yml:dp-cantabular-api-ext.yml:dp-dataset-api.yml:dp-cantabular-csv-exporter.yml:dp-cantabular-dimension-api.yml:dp-filter-api.yml:dp-cantabular-filter-flex-api.yml:dp-cantabular-metadata-service.yml:dp-cantabular-metadata-exporter.yml:dp-cantabular-xlsx-exporter.yml:dp-recipe-api.yml:zebedee.yml:dp-download-service.yml:dp-population-types-api.yml
22
COMPOSE_PATH_SEPARATOR=:
33
COMPOSE_PROJECT_NAME=cantabular-import-journey

cantabular-import/elk.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
version: '3.3'
2+
services:
3+
logstash:
4+
image: logstash:7.16.2
5+
container_name: logstash
6+
restart: always
7+
volumes:
8+
- ./elk/logstash/logstash.conf:/etc/logstash/logstash.conf
9+
command: logstash -f /etc/logstash/logstash.conf
10+
depends_on:
11+
- elasticsearch
12+
ports:
13+
- '5044:5044'
14+
environment:
15+
LS_JAVA_OPTS: "-Xmx256m -Xms256m"
16+
17+
elasticsearch:
18+
image: elasticsearch:7.16.2
19+
container_name: elasticsearch
20+
restart: always
21+
volumes:
22+
- ./elk/elasticsearch_data:/usr/share/elasticsearch/data/
23+
environment:
24+
ES_JAVA_OPTS: "-Xmx256m -Xms256m"
25+
discovery.type: single-node
26+
ports:
27+
- '9200:9200'
28+
- '9300:9300'
29+
30+
kibana:
31+
image: kibana:7.16.2
32+
container_name: kibana
33+
restart: always
34+
ports:
35+
- '5601:5601'
36+
environment:
37+
- ELASTICSEARCH_URL=http://elasticsearch:9200
38+
depends_on:
39+
- elasticsearch
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
input {
2+
tcp {
3+
port => 5044
4+
}
5+
}
6+
7+
output {
8+
elasticsearch {
9+
hosts => ["http://elasticsearch:9200"]
10+
index => "containers-%{+YYYY.MM.dd}"
11+
}
12+
}

0 commit comments

Comments
 (0)