Hi Peter,
Thank you for response. Exactly, what i was looking for.
On the side note, how would I implement sFlow forwarding during container build ?
My Dockerfile looks like this without forwarding and everything works great:
===========================================
FROM sflow/sflow-rt:latest
RUN /sflow-rt/get-app.sh sflow-rt browse-metrics && /sflow-rt/get-app.sh sflow-rt browse-flows && /sflow-rt/get-app.sh sflow-rt prometheus && /sflow-rt/get-app.sh sflow-rt flow-trend && /sflow-rt/get-app.sh sflow-rt top-flows && /sflow-rt/get-app.sh sflow-rt ddos-protect && /sflow-rt/get-app.sh sflow-rt ddos-blackhole
===========================================
2021-05-19T17:10:00Z INFO: Starting sFlow-RT 3.0-1549
2021-05-19T17:10:00Z INFO: Version check, 3.0-1591 available
2021-05-19T17:10:00Z INFO: Listening, sFlow port 6343
2021-05-19T17:10:01Z INFO: Listening, HTTP port 8008
2021-05-19T17:10:01Z INFO: app/ddos-blackhole/scripts/ddos.js started
2021-05-19T17:10:01Z INFO: app/browse-flows/scripts/top.js started
2021-05-19T17:10:01Z INFO: app/ddos-protect/scripts/ddos.js started
2021-05-19T17:10:01Z INFO: app/top-flows/scripts/top.js started
2021-05-19T17:10:01Z INFO: app/prometheus/scripts/export.js started
2021-05-19T17:10:01Z INFO: app/flow-trend/scripts/top.js started
When I add ENTRYPOINT.sh
==========================================================
#!/bin/sh
### Enable sFlow forwarding
====================================================================
I get connection refused as the curl was executed before the application started.
curl: (7) Failed to connect to 127.0.0.1 port 8008: Connection refused
==============================================================
How can I enabled sflow forwarding via Dockerfile so that forwarding is applied after application is started ?
Thank you for your help.