Browse Source

fluent

master
zeus 3 years ago
parent
commit
0b05f60b18
  1. 15
      WriteToMongo/fluent/install-fluent.sh
  2. 24
      docker-compose.yml

15
WriteToMongo/fluent/install-fluent.sh

@ -0,0 +1,15 @@
#!/bin/sh
BASEDIR=$(dirname $0)
cpwd=$PWD
echo $BASEDIR
cd $BASEDIR
gem install fluent-plugin-mongo \
gem sources --clear-all \
rm -rf /tmp/* /var/tmp/* /usr/lib/ruby/gems/*/cache/*.gem
cp fluent.conf /fluentd/etc/
cp entrypoint.sh /bin/

24
docker-compose.yml

@ -1,11 +1,17 @@
version: "3.3" version: "3.3"
services: services:
webclient:
image: hub.swarmlab.io:5480/poc-datacollector-node:latest
container_name: webclient
ports:
- "8085:8080"
networks:
datacollector-net:
redisserver: redisserver:
#image: hub.swarmlab.io:5480/playground-redisserver:latest #image: hub.swarmlab.io:5480/playground-redisserver:latest
container_name: redisserver #container_name: redisserver
depends_on: container_name: redis:6.2.6-alpine
- writetomongo
logging: logging:
driver: "fluentd" driver: "fluentd"
options: options:
@ -15,7 +21,7 @@ services:
ports: ports:
- "6379:6379" - "6379:6379"
networks: networks:
playground-net: datacollector-net:
writetomongo: writetomongo:
image: writemongo:latest image: writemongo:latest
container_name: fluentd container_name: fluentd
@ -27,7 +33,7 @@ services:
- "24224:24224" - "24224:24224"
- "24224:24224/udp" - "24224:24224/udp"
networks: networks:
playground-net: datacollector-net:
readmongo: readmongo:
container_name: readmongo_service container_name: readmongo_service
restart: always restart: always
@ -47,7 +53,7 @@ services:
links: links:
- mongo - mongo
networks: networks:
playground-net: datacollector-net:
dummy: dummy:
container_name: dummy_service container_name: dummy_service
restart: always restart: always
@ -67,7 +73,7 @@ services:
links: links:
- mongo - mongo
networks: networks:
playground-net: datacollector-net:
# ---- fluentd service ---- # ---- fluentd service ----
mongo: mongo:
container_name: mongo container_name: mongo
@ -82,7 +88,7 @@ services:
ports: ports:
- "27017:27017" - "27017:27017"
networks: networks:
playground-net: datacollector-net:
# volumes: # volumes:
# fluent: # fluent:
@ -90,4 +96,4 @@ services:
# dummy: # dummy:
networks: networks:
playground-net: datacollector-net:

Loading…
Cancel
Save