Skip to content

Commit

Permalink
fix(telegraf) ensure off-cluster influxdb url is quoted
Browse files Browse the repository at this point in the history
  • Loading branch information
croemmich committed Mar 13, 2017
1 parent 2e62180 commit a1e3fef
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions telegraf/rootfs/start-telegraf
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,11 @@ if [ -n "$ENABLE_PROMETHEUS" ]; then
echo "Setting PROMETHEUS_URLS: $PROMETHEUS_URLS"
fi

# if the influxdb url does not start with a quote, assume it's singular and quote it
if [ ${INFLUXDB_URLS:0:1} != "\"" ]; then
export INFLUXDB_URLS="\"$INFLUXDB_URLS\""
fi

echo "Building config.toml!"
envtpl -in config.toml.tpl | sed '/^$/d' > config.toml

Expand Down

0 comments on commit a1e3fef

Please sign in to comment.