1
0
mirror of https://github.com/mainflux/mainflux.git synced 2025-04-24 13:48:49 +08:00
b1ackd0t 8b185d205b
MF - 1758 - Sync With Benchmark Testing (#1912)
* feat(docker): add trace ration and max conn

This adds a new environment variable `MF_JAEGER_TRACE_RATIO` to the `docker/.env` file. The variable is used to set the ratio of requests traced.

Additionally, this commit also adds a new environment variable `MF_POSTGRES_MAX_CONNECTIONS` for configuring the maximum number of connections for the Postgres database.

These changes are made to enhance the configuration and scalability of the core services.

Signed-off-by: Rodney Osodo <28790446+rodneyosodo@users.noreply.github.com>

* Remove comment to trace ratio

Signed-off-by: rodneyosodo <blackd0t@protonmail.com>

* Reduce postgres max connection to 100

Signed-off-by: rodneyosodo <blackd0t@protonmail.com>

---------

Signed-off-by: Rodney Osodo <28790446+rodneyosodo@users.noreply.github.com>
Signed-off-by: rodneyosodo <blackd0t@protonmail.com>
2023-10-24 18:59:49 +02:00

52 lines
1.8 KiB
YAML

# Copyright (c) Mainflux
# SPDX-License-Identifier: Apache-2.0
# This docker-compose file contains optional opcua-adapter and opcua-redis services
# for the Mainflux platform. Since this services are optional, this file is dependent on the
# docker-compose.yml file from <project_root>/docker/. In order to run these services,
# core services, as well as the network from the core composition, should be already running.
version: "3.7"
networks:
mainflux-base-net:
volumes:
mainflux-opcua-adapter-volume:
mainflux-opcua-redis-volume:
services:
opcua-redis:
image: redis:7.2.0-alpine
container_name: mainflux-opcua-redis
restart: on-failure
networks:
- mainflux-base-net
volumes:
- mainflux-opcua-redis-volume:/data
opcua-adapter:
image: mainflux/opcua:${MF_RELEASE_TAG}
container_name: mainflux-opcua
restart: on-failure
environment:
MF_OPCUA_ADAPTER_LOG_LEVEL: ${MF_OPCUA_ADAPTER_LOG_LEVEL}
MF_OPCUA_ADAPTER_EVENT_CONSUMER: ${MF_OPCUA_ADAPTER_EVENT_CONSUMER}
MF_OPCUA_ADAPTER_HTTP_HOST: ${MF_OPCUA_ADAPTER_HTTP_HOST}
MF_OPCUA_ADAPTER_HTTP_PORT: ${MF_OPCUA_ADAPTER_HTTP_PORT}
MF_OPCUA_ADAPTER_HTTP_SERVER_CERT: ${MF_OPCUA_ADAPTER_HTTP_SERVER_CERT}
MF_OPCUA_ADAPTER_HTTP_SERVER_KEY: ${MF_OPCUA_ADAPTER_HTTP_SERVER_KEY}
MF_OPCUA_ADAPTER_ES_URL: ${MF_ES_STORE_URL}
MF_OPCUA_ADAPTER_ROUTE_MAP_URL: ${MF_OPCUA_ADAPTER_ROUTE_MAP_URL}
MF_MESSAGE_BROKER_URL: ${MF_MESSAGE_BROKER_URL}
MF_JAEGER_URL: ${MF_JAEGER_URL}
MF_JAEGER_TRACE_RATIO: ${MF_JAEGER_TRACE_RATIO}
MF_SEND_TELEMETRY: ${MF_SEND_TELEMETRY}
MF_OPCUA_ADAPTER_INSTANCE_ID: ${MF_OPCUA_ADAPTER_INSTANCE_ID}
ports:
- ${MF_OPCUA_ADAPTER_HTTP_PORT}:${MF_OPCUA_ADAPTER_HTTP_PORT}
networks:
- mainflux-base-net
volumes:
- mainflux-opcua-adapter-volume:/store