Update Dockerfile.dev

This commit is contained in:
Eugene Burmakin 2025-09-30 20:27:02 +02:00
parent 4e9e1e933a
commit e8cc4c5b8b

View file

@ -33,10 +33,18 @@ RUN apt-get update -qq && DEBIAN_FRONTEND=noninteractive apt-get install -y --no
&& rm -rf /var/lib/apt/lists/*
# Install Node.js using official NodeSource script
RUN curl -fsSL https://deb.nodesource.com/setup_22.x | bash - \
&& apt-get install -y nodejs \
&& npm install -g yarn \
&& rm -rf /var/lib/apt/lists/*
# NodeSource supports: amd64, arm64, armhf (arm/v7)
# For unsupported architectures, fall back to Debian's nodejs package
RUN ARCH=$(dpkg --print-architecture) && \
if [ "$ARCH" = "amd64" ] || [ "$ARCH" = "arm64" ] || [ "$ARCH" = "armhf" ]; then \
curl -fsSL https://deb.nodesource.com/setup_22.x | bash - && \
apt-get install -y nodejs; \
else \
apt-get update && \
apt-get install -y nodejs npm; \
fi && \
npm install -g yarn && \
rm -rf /var/lib/apt/lists/*
# Use jemalloc with check for architecture
RUN if [ "$(uname -m)" = "x86_64" ]; then \