Files
d53e5f9b5a compose: update Clickhouse schema to match casing of proto (#133)
This commit resolves an issue with the mapping between the ClickHouse
schema and the flow.proto schema.

In 3326554, the casing of the proto fields was updated, but the
ClickHouse column names were not also updated, resulting in the
ClickHouse Kafka engine only being able to successfully deserialize
fields that without an underscore.

Also updates the provisioned dashboards. Versions of the tools are also updated.

Co-authored-by: lspgn <[email protected]>
2023-03-06 20:39:33 -08:00

72 lines
1.9 KiB
YAML

version: "3"
services:
zookeeper:
image: bitnami/zookeeper:3.7.1
ports:
- 2181:2181
environment:
- ALLOW_ANONYMOUS_LOGIN=yes
restart: always
kafka:
image: bitnami/kafka:3.4.0
ports:
- 9092:9092
environment:
- KAFKA_ZOOKEEPER_CONNECT=zookeeper:2181
- ALLOW_PLAINTEXT_LISTENER=yes
- KAFKA_DELETE_TOPIC_ENABLE=true
restart: always
depends_on:
- zookeeper
grafana:
image: grafana/grafana:9.4.3
environment:
- GF_INSTALL_PLUGINS=vertamedia-clickhouse-datasource
# - GF_INSTALL_PLUGINS=grafana-clickhouse-datasource
# - GF_PLUGINS_ALLOW_LOADING_UNSIGNED_PLUGINS=vertamedia-clickhouse-datasource
ports:
- 3000:3000
restart: always
volumes:
- ./grafana/datasources-ch.yml:/etc/grafana/provisioning/datasources/datasources-ch.yml
- ./grafana/dashboards.yml:/etc/grafana/provisioning/dashboards/dashboards.yml
- ./grafana/dashboards:/var/lib/grafana/dashboards
prometheus:
image: prom/prometheus:v2.37.6
ports:
- 9090:9090
restart: always
volumes:
- ./prometheus/prometheus.yml:/etc/prometheus/prometheus.yml
goflow2:
build:
context: ../../
dockerfile: Dockerfile
args:
VERSION: compose
LDFLAGS: -X main.version=compose
image: netsampler/goflow2
depends_on:
- kafka
ports:
- 8080:8080
- 6343:6343/udp
- 2055:2055/udp
restart: always
command:
- -transport.kafka.brokers=kafka:9092
- -transport=kafka
- -transport.kafka.topic=flows
- -format=pb
- -format.protobuf.fixedlen=true
db:
image: clickhouse/clickhouse-server:22.8.14.53-alpine
ports:
- 8123:8123
volumes:
- ./clickhouse:/docker-entrypoint-initdb.d/
- ../../pb/flow.proto:/var/lib/clickhouse/format_schemas/flow.proto
- ./clickhouse/protocols.csv:/var/lib/clickhouse/user_files/protocols.csv
depends_on:
- kafka