Skip to content

[chore] Upgrade NodeJS instrumentation to latest #6162

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Apr 22, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion instrumentation/packaging/nodejs-agent-release.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v2.15.0
v3.1.2
2 changes: 1 addition & 1 deletion packaging/tests/deployments/salt/images/Dockerfile.deb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ FROM ${DISTRO_IMAGE}
ARG DISTRO_IMAGE
ENV DEBIAN_FRONTEND=noninteractive
ENV SALT_VERSION=latest
ENV NODE_VERSION=16.20.2
ENV NODE_VERSION=18.20.8

RUN apt-get update && apt-get upgrade -y -o DPkg::Options::=--force-confold
RUN apt-get install -y software-properties-common ca-certificates wget curl apt-transport-https python3-pip vim systemd procps
Expand Down
2 changes: 1 addition & 1 deletion packaging/tests/deployments/salt/images/Dockerfile.rpm
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ ARG DISTRO_IMAGE
ARG PKG_MGR=dnf
ENV DEBIAN_FRONTEND=noninteractive
ENV SALT_VERSION=latest
ENV NODE_VERSION=16.20.2
ENV NODE_VERSION=18.20.8
ENV container=docker

# config for centos
Expand Down
24 changes: 0 additions & 24 deletions packaging/tests/images/deb/Dockerfile.ubuntu-bionic

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ COPY --from=tomcat /opt/java /opt/java
COPY instrumentation/setup-tomcat.sh /opt/
RUN bash /opt/setup-tomcat.sh

ARG NODE_VERSION=v16
ARG NODE_VERSION=v18
COPY instrumentation/setup-express.sh /opt
RUN bash /opt/setup-express.sh

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ COPY --from=tomcat /opt/java /opt/java
COPY instrumentation/setup-tomcat.sh /opt/
RUN bash /opt/setup-tomcat.sh

ARG NODE_VERSION=v16
ARG NODE_VERSION=v18
COPY instrumentation/setup-express.sh /opt
RUN bash /opt/setup-express.sh

Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ COPY --from=tomcat /opt/java /opt/java
COPY instrumentation/setup-tomcat.sh /opt/
RUN bash /opt/setup-tomcat.sh

ARG NODE_VERSION=v16
ARG NODE_VERSION=v18
COPY instrumentation/setup-express.sh /opt
RUN bash /opt/setup-express.sh

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ COPY --from=tomcat /opt/java /opt/java
COPY instrumentation/setup-tomcat.sh /opt/
RUN bash /opt/setup-tomcat.sh

ARG NODE_VERSION=v16
ARG NODE_VERSION=v18
COPY instrumentation/setup-express.sh /opt
RUN bash /opt/setup-express.sh

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ COPY --from=tomcat /opt/java /opt/java
COPY instrumentation/setup-tomcat.sh /opt/
RUN bash /opt/setup-tomcat.sh

ARG NODE_VERSION=v16
ARG NODE_VERSION=v18
COPY instrumentation/setup-express.sh /opt
RUN bash /opt/setup-express.sh

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ COPY --from=tomcat /opt/java /opt/java
COPY instrumentation/setup-tomcat.sh /opt/
RUN bash /opt/setup-tomcat.sh

ARG NODE_VERSION=v16
ARG NODE_VERSION=v18
COPY instrumentation/setup-express.sh /opt
RUN bash /opt/setup-express.sh

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ COPY --from=tomcat /opt/java /opt/java
COPY instrumentation/setup-tomcat.sh /opt/
RUN bash /opt/setup-tomcat.sh

ARG NODE_VERSION=v16
ARG NODE_VERSION=v18
COPY instrumentation/setup-express.sh /opt
RUN bash /opt/setup-express.sh

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ COPY --from=tomcat /opt/java /opt/java
COPY instrumentation/setup-tomcat.sh /opt/
RUN bash /opt/setup-tomcat.sh

ARG NODE_VERSION=v16
ARG NODE_VERSION=v18
COPY instrumentation/setup-express.sh /opt
RUN bash /opt/setup-express.sh

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ COPY --from=tomcat /opt/java /opt/java
COPY instrumentation/setup-tomcat.sh /opt/
RUN bash /opt/setup-tomcat.sh

ARG NODE_VERSION=v16
ARG NODE_VERSION=v18
COPY instrumentation/setup-express.sh /opt
RUN bash /opt/setup-express.sh

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ COPY --from=tomcat /opt/java /opt/java
COPY instrumentation/setup-tomcat.sh /opt/
RUN bash /opt/setup-tomcat.sh

ARG NODE_VERSION=v16
ARG NODE_VERSION=v18
COPY instrumentation/setup-express.sh /opt
RUN bash /opt/setup-express.sh

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ COPY --from=tomcat /opt/java /opt/java
COPY instrumentation/setup-tomcat.sh /opt/
RUN bash /opt/setup-tomcat.sh

ARG NODE_VERSION=v16
ARG NODE_VERSION=v18
COPY instrumentation/setup-express.sh /opt
RUN bash /opt/setup-express.sh

Expand Down
4 changes: 2 additions & 2 deletions packaging/tests/instrumentation/instrumentation_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -329,8 +329,8 @@ def test_express_instrumentation(distro, arch):
assert pkg_path, f"{PKG_NAME} package not found"
pkg_base = os.path.basename(pkg_path)

# minimum supported node version required for profiling
node_version = 16
# minimum supported node version
node_version = 18

buildargs = {"NODE_VERSION": f"v{node_version}"}

Expand Down
4 changes: 1 addition & 3 deletions packaging/tests/instrumentation/setup-express.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,7 @@ HOME=$NVM_HOME bash -c 'curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0
NVM_DIR="$NVM_HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"

nvm install --default ${NODE_VERSION:-v16}

npm config --global set user root
nvm install --default ${NODE_VERSION:-v18} --unsafe-perm

NODE_PATH="$( npm root -g )"

Expand Down
Loading