From 944f9196e11d28ecc1ff78e6d678a5afb033f47c Mon Sep 17 00:00:00 2001 From: Sergio Nicolas Lavaise Date: Mon, 10 Aug 2026 07:45:59 +0000 Subject: [PATCH] fix: use ubuntu:22.04 base image with NodeSource Node.js 20 in Dockerfile --- Dockerfile | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 0243415..87d001b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -11,20 +11,23 @@ RUN npm ci COPY . . RUN VITE_API_URL=$VITE_API_URL npm run build -# Stage 2: Production environment with Node.js, Nginx, and MongoDB Community Edition (ARM64 & AMD64 native support via Ubuntu 22.04 Jammy) -FROM node:20-jammy +# Stage 2: Production environment with Node.js, Nginx, and MongoDB Community Edition (ARM64 & AMD64 native support via Ubuntu 22.04) +FROM ubuntu:22.04 WORKDIR /app # Prevent interactive prompts during apt install ENV DEBIAN_FRONTEND=noninteractive -# Install dependencies needed for MongoDB repo and general setup +# Install dependencies needed for Node.js, MongoDB repo, and general setup RUN apt-get update && apt-get install -y \ gnupg \ curl \ + ca-certificates \ nginx \ procps \ + && curl -fsSL https://deb.nodesource.com/setup_20.x | bash - \ + && apt-get install -y nodejs \ && rm -rf /var/lib/apt/lists/* # Add MongoDB official GPG key and repository (MongoDB 8.0 for Ubuntu 22.04 Jammy - supports arm64 and amd64 natively)