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

Loading…
Cancel
Save