1
0
mirror of https://github.com/mainflux/mainflux.git synced 2025-05-09 19:29:29 +08:00
Arvindh fde435060c
NOISSUE - Implementation of gRPC mTLS (#1848)
Rebase with master and squash commits
add: rootCA and clientCA in grpc server
add: rootCA and client certificate in grpc client
add: docker-compose for grpc-mtls and make target for mtls cert generation
fix: typo in makefile
fix: loadCertFile function in internal/clients/grpc/connect.go
fix: env.parser test
remove: commented lines
add: make commands
update: make commands and grpc clients
fix: typo in makefile
fix: loadCertFile function in internal/clients/grpc/connect.go
remove: commented lines
update: make commands and grpc clients
update: make commands and docker-compose
add: end of line
fix: typos in makefile
add: end of line
fix: typos in makefile
revert: grafana port in .env
change: loadCertFile function
change: certficate logic
change: env name and update in compose file
fix: makefile
remove: tls env var
change: ioutil to os for ReadFile
change loadfile
remove: test which is no needed
fix: docker project name
single docker-compose file
single docker-compose file
single docker-compose file
fix space and new lines
fix makefile
add: GRPC_TLS varaible and imporved logging in gRPC Client
fix mtls and tls env vars
fix mtls and tls env vars
grpc_mtls
fix docker-compose
fix makefile
fix const name to go idomatic

---------

Signed-off-by: Arvindh <arvindh91@gmail.com>
2023-08-16 19:11:33 +02:00

56 lines
1.6 KiB
YAML

# Copyright (c) Mainflux
# SPDX-License-Identifier: Apache-2.0
# This docker-compose file contains optional Prometheus and Grafana service for Mainflux platform.
# Since this service is optional, this file is dependent of docker-compose.yml file
# from <project_root>/docker. In order to run this service, execute command:
# docker-compose -f docker/addons/prometheus/docker-compose.yml up
# from project root.
version: "3.7"
networks:
mainflux-base-net:
volumes:
mainflux-prometheus-volume:
services:
promethues:
image: prom/prometheus:v2.42.0
container_name: mainflux-prometheus
restart: on-failure
ports:
- ${MF_PROMETHEUS_PORT}:${MF_PROMETHEUS_PORT}
networks:
- mainflux-base-net
volumes:
- type: bind
source: ./metrics/prometheus.yml
target: /etc/prometheus/prometheus.yml
- mainflux-prometheus-volume:/prometheus
grafana:
image: grafana/grafana:9.4.7
container_name: mainflux-grafana
depends_on:
- promethues
restart: on-failure
ports:
- ${MF_GRAFANA_PORT}:${MF_GRAFANA_PORT}
environment:
- GF_SECURITY_ADMIN_USER=${MF_GRAFANA_ADMIN_USER}
- GF_SECURITY_ADMIN_PASSWORD=${MF_GRAFANA_ADMIN_PASSWORD}
networks:
- mainflux-base-net
volumes:
- type: bind
source: ./grafana/datasource.yml
target: /etc/grafana/provisioning/datasources/datasource.yml
- type: bind
source: ./grafana/dashboard.yml
target: /etc/grafana/provisioning/dashboards/main.yaml
- type: bind
source: ./grafana/example-dashboard.json
target: /var/lib/grafana/dashboards/example-dashboard.json