Skip to content

Commit

Permalink
Merge pull request #13 from boomzillawtf/perf
Browse files Browse the repository at this point in the history
Performance tools
  • Loading branch information
boomzillawtf committed Jun 24, 2016
2 parents 76230be + 9568468 commit 50408f2
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Dockerfile
Expand Up @@ -39,4 +39,4 @@ RUN ln -s /usr/src/app/docker/config.json /usr/src/app/config.json
CMD cat .make-uploads-folders | xargs mkdir -p \
&& ./nodebb upgrade \
&& echo 1 > pidfile \
&& exec node loader.js
&& exec node --perf-basic-prof-only-functions loader.js
9 changes: 9 additions & 0 deletions collect-stacks.bash
@@ -0,0 +1,9 @@
#!/usr/bin/env bash
set -e
DOCKER_PID=$1
HOST_PID=$2

docker cp wtdwtf-nodebb:/tmp/perf-$DOCKER_PID.map /tmp/perf-$HOST_PID.map
chown root /tmp/perf-$HOST_PID.map
perf record -F 99 -p $HOST_PID -g -- sleep 30
perf script > nodestacks
1 change: 1 addition & 0 deletions setup.bash
Expand Up @@ -36,6 +36,7 @@ else
nodebb-upstream.conf for a webserver running on the host."
fi


# pull the NodeBB image
docker pull boomzillawtf/tdwtf

Expand Down

0 comments on commit 50408f2

Please sign in to comment.