[VOL-634] Remove fluentd logging reference from voltha services
This update removes the "hardcoded" logging framework (fluentd)
from the voltha, ofagent and netconf services. The logging is
now determined at deployment time. Testing was done in kubernetes
environment and minimally in docker swarm mode environment (docker
swarm mode is not required for voltha 1.3). A separate Jira will
be raised to adjust the docker swarm deployment files, i.e. direct
the logs to fluentd/fluentd-agg listen ports instead of writing locally.
Change-Id: Ic780fc9633f0f833f961c97dc59d89eed2112a53
diff --git a/compose/docker-compose-system-test-persistence.yml b/compose/docker-compose-system-test-persistence.yml
index 99f42eb..57d0006 100644
--- a/compose/docker-compose-system-test-persistence.yml
+++ b/compose/docker-compose-system-test-persistence.yml
@@ -114,11 +114,15 @@
#
voltha:
image: "${REGISTRY}${REPOSITORY}voltha-voltha${TAG}"
+ logging:
+ driver: "json-file"
+ options:
+ max-size: "10m"
+ max-file: "3"
command: [
"/voltha/voltha/main.py",
"-v",
"--consul=${DOCKER_HOST_IP}:8500",
- "--fluentd=fluentd:24224",
"--rest-port=8880",
"--grpc-port=50556",
"--kafka=@kafka",
@@ -135,7 +139,6 @@
- vconsul
links:
- vconsul
- - fluentd
environment:
SERVICE_8880_NAME: "voltha-health"
SERVICE_8880_CHECK_HTTP: "/health"
@@ -202,11 +205,15 @@
#
ofagent:
image: "${REGISTRY}${REPOSITORY}voltha-ofagent${TAG}"
+ logging:
+ driver: "json-file"
+ options:
+ max-size: "10m"
+ max-file: "3"
command: [
"/ofagent/ofagent/main.py",
"-v",
"--consul=${DOCKER_HOST_IP}:8500",
- "--fluentd=fluentd:24224",
"--controller=${DOCKER_HOST_IP}:6653",
"--grpc-endpoint=@voltha-grpc",
"--instance-id-is-container-name",
@@ -217,7 +224,6 @@
- voltha
links:
- vconsul
- - fluentd
volumes:
- "/var/run/docker.sock:/tmp/docker.sock"
restart: unless-stopped
@@ -227,12 +233,16 @@
#
netconf:
image: "${REGISTRY}${REPOSITORY}voltha-netconf${TAG}"
+ logging:
+ driver: "json-file"
+ options:
+ max-size: "10m"
+ max-file: "3"
privileged: true
command: [
"/netconf/netconf/main.py",
"-v",
"--consul=${DOCKER_HOST_IP}:8500",
- "--fluentd=fluentd:24224",
"--grpc-endpoint=@voltha-grpc",
"--instance-id-is-container-name",
"-v"
@@ -244,7 +254,6 @@
- voltha
links:
- vconsul
- - fluentd
environment:
SERVICE_1830_NAME: "netconf-server"
volumes: