-
Notifications
You must be signed in to change notification settings - Fork 68
fix: --opbeans-node-agent-local-repo=/a/local/dir #1084
Conversation
Fixes './scripts/compose.py start --opbeans-node-agent-local-repo=$dir' to (a) install the Node.js APM agent into the opbeans-node app at "/app" and (b) to skip copying the possibly large node_modules and build dirs for speed. Fixes: elastic#1083
echo "Installing from local folder" | ||
# copy to folder inside container to ensure were not poluting the local folder | ||
cp -r /local-install ~ | ||
cd ~/local-install && npm install . |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This npm install .
was installing the deps for the apm-agent-nodejs copy in ~/local-install, but it wasn't installing them where the app at "/app" would use it.
docker/opbeans/node/entrypoint.sh
Outdated
echo "Installing elastic-apm-node from local folder (--opbeans-node-agent-local-repo)" | ||
# Copy to a folder inside container to ensure we're not polluting the | ||
# local folder. Skip possibly huge dirs to speed this up. | ||
apk add rsync |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is installing rsync appropriate here? Would doing so in the Dockerfile be more appropriate?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it is better to add packages on the Dockerfile
…epo, it should work fine now
💚 Build Succeeded
Expand to view the summary
Build stats
Test stats 🧪
Trends 🧪 |
💚 Build Succeeded
Expand to view the summary
Build stats
Test stats 🧪
Trends 🧪 |
…rt-from-build * upstream/master: (24 commits) Add mergify (elastic#1089) fix: update flake8 and deps to work with Python 3.8+ (elastic#1085) chore: bump elastic stack (elastic#1087) fix: force to activate venv (elastic#1086) fix: --opbeans-node-agent-local-repo=/a/local/dir (elastic#1084) ci: jjbb remove periodic-folder-trigger (elastic#1079) Fix APM Server managed by Elastic Agent setup (elastic#1078) docker/opbeans/go: use -mod=mod (elastic#1077) [fleet] fix elastic-agent setup (elastic#1076) update supported stack versions (elastic#1075) [CI] Increase timeout (elastic#1070) Add --package-registry-url flag (elastic#1069) Create opbeans_user/role with write/read access for the opbeans-python (elastic#1063) reset postgres sequences after database migration (elastic#1062) chore: bump Elastic Stack (elastic#1060) docker/go/nethttp: go build -mod=mod (elastic#1061) check agent liveness via version subcommand (elastic#1059) test: use filebeat step to grab Docker logs (elastic#1029) Update dotnet sdk 5.0 docker image (elastic#1048) docs: using Dyno (elastic#1056) ...
Fixes './scripts/compose.py start --opbeans-node-agent-local-repo=$dir' to (a) install the Node.js APM agent into the opbeans-node app at "/app" and (b) to skip copying the possibly large node_modules and build dirs for speed. Fixes: elastic#1083 # Conflicts: # README.md
Fixes './scripts/compose.py start --opbeans-node-agent-local-repo=$dir' to (a) install the Node.js APM agent into the opbeans-node app at "/app" and (b) to skip copying the possibly large node_modules and build dirs for speed. Fixes: #1083 # Conflicts: # README.md
What does this PR do?
Fixes './scripts/compose.py start --opbeans-node-agent-local-repo=$dir'
to (a) install the Node.js APM agent into the opbeans-node app at "/app"
and (b) to skip copying the possibly large node_modules and build dirs
for speed.
Why is it important?
Otherwise the starting of the opbeans-node container is potentially very slow and doesn't run the Node.js APM agent code one expects.
Related issues
Fixes: #1083