Last active
May 4, 2017 23:14
-
-
Save joshwand/9174513e909c3652accc73fa9daeade7 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -e | |
set -x | |
COLLECTOR_IP=${COLLECTOR_IP:-127.0.0.1} | |
COLLECTOR_TCP_PORT=${COLLECTOR_TCP_PORT:-9994} | |
COLLECTOR_UDP_STAT_LISTEN_PORT=${COLLECTOR_UDP_STAT_LISTEN_PORT:-9995} | |
COLLECTOR_UDP_SPAN_LISTEN_PORT=${COLLECTOR_UDP_SPAN_LISTEN_PORT:-9996} | |
DISABLE_DEBUG=${DISABLE_DEBUG:-true} | |
curl -SL https://raw.githubusercontent.com/naver/pinpoint/1.6.x/agent/src/main/resources-release/pinpoint.config -o /assets/pinpoint.config | |
curl -SL https://raw.githubusercontent.com/naver/pinpoint/1.6.x/agent/src/main/resources-release/lib/log4j.xml -o /assets/lib/log4j.xml | |
echo "fooo" | |
echo `ls -lr /assets/` | |
cp -f /assets/pinpoint.config /assets/pinpoint-agent/pinpoint.config | |
sed -i "s/profiler.collector.ip=127.0.0.1/profiler.collector.ip=${COLLECTOR_IP}/g" /assets/pinpoint-agent/pinpoint.config | |
sed -i "s/profiler.collector.tcp.port=9994/profiler.collector.tcp.port=${COLLECTOR_TCP_PORT}/g" /assets/pinpoint-agent/pinpoint.config | |
sed -i "s/profiler.collector.stat.port=9995/profiler.collector.stat.port=${COLLECTOR_UDP_STAT_LISTEN_PORT}/g" /assets/pinpoint-agent/pinpoint.config | |
sed -i "s/profiler.collector.span.port=9996/profiler.collector.span.port=${COLLECTOR_UDP_SPAN_LISTEN_PORT}/g" /assets/pinpoint-agent/pinpoint.config | |
if [ "$DISABLE_DEBUG" == "true" ]; then | |
sed -i 's/level value="DEBUG"/level value="INFO"/' /assets/lib/log4j.xml | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment