Skip to main content
Microsoft
separator
https://catalogartifact.azureedge.net/publicartifacts/cloudimg1647283583153.nodejs-22-ubuntu-24-04-10e3c2d0-c96e-4a4b-ac5e-a3a5f66cb825/image0_logolarge.png

Node.js 22 LTS Ubuntu 24.04

by cloudimg

Production Node.js 22 LTS for APIs and web apps. PM2, nginx, per-VM secrets. 24/7 cloudimg support

Node.js 22 LTS on Ubuntu 24.04 by cloudimg

Pre configured Node.js 22.22.2 (the current Active LTS line, codename Jod, supported through April 2027) on Ubuntu 24.04 LTS, purpose built for Microsoft Azure and maintained by cloudimg. Node.js is the de facto server side JavaScript runtime — built on Google's V8 engine, with a non blocking event loop, and the largest open source package ecosystem in software (npm registry exceeds 3 million packages). This image ships a production typical stack so customers can drop their own Express, Fastify, Nest.js, Next.js, or Hapi application onto a hardened, secret rotated VM and start serving traffic in minutes.

Why Choose cloudimg?

  • 24/7 Expert Support Guaranteed 24 hour response, one hour average for critical issues. support@cloudimg.co.uk
  • Production Ready from Launch Pre configured, security patched, validated
  • Azure Native Integration Azure Linux Agent, cloud init, Gen2 Hyper V with UEFI boot
  • Per VM Auth Wall SESSION_SECRET (32 hex) and ADMIN_API_KEY (32 hex) rotated at first boot, written to /stage/scripts/nodejs-credentials.log mode 0600 root only and exposed to Node via /etc/nodeapp/cloudimg.env mode 0640 root:nodeapp

What is Included

  • Node.js 22.22.2 LTS from the official NodeSource APT repository (deb.nodesource.com), MIT licensed
  • Bundled npm 10.9.x — the standard JavaScript package manager
  • pnpm installed globally — fast, disk efficient alternative to npm with content addressable storage
  • PM2 installed globally — production grade process manager with cluster mode, log rotation, and zero downtime reload
  • nginx 1.24 from Ubuntu noble main, terminating HTTP on TCP 80 and reverse proxying to the Node app on 127.0.0.1:3000
  • Express 4 + EJS templating + helmet security headers + morgan request logging + ws WebSocket library — installed via `npm install --omit=dev` at build time so the customer VM boots with no network dependency
  • Sample app at /opt/nodeapp/cloudimg owned by the unprivileged `nodeapp` system user (home /var/lib/nodeapp, shell /usr/sbin/nologin) demonstrating a homepage, JSON API at /api/info, admin endpoint at /api/admin protected by the per VM API key, and a WebSocket echo demo at /ws
  • Static assets at /opt/nodeapp/cloudimg/public served directly by nginx for /static/ requests (faster than going through Node)
  • systemd units: cloudimg-app.service (Type=simple, ExecStart wraps pm2-runtime under bash for env expansion), nginx.service, and nodejs-firstboot.service (oneshot)
  • PM2 invoked through pm2-runtime (not pm2 start) so the process manager stays in foreground and pipes logs straight to the systemd journal — exactly the pattern PM2 documents for systemd integration
  • Ubuntu 24.04 LTS (Noble Numbat) base with full apt dist-upgrade applied at build time

Use Cases

  • REST APIs and JSON microservices — Express, Fastify, Hapi, Nest.js
  • Real time apps — WebSocket chat, collaborative editing, live dashboards (sample /ws echo demo demonstrates the wiring)
  • Server side rendering — Next.js, Nuxt, Remix, Astro SSR backends behind nginx
  • JavaScript build tooling — Vite, Webpack, Turbopack, esbuild build servers
  • Backend for frontend (BFF) layer translating between client apps and downstream APIs
  • Migration target for Node.js 18 EOL workloads onto an Active LTS runtime

Getting Started

1. Deploy from the Azure Marketplace

2. SSH as azureuser, sudo cat /stage/scripts/nodejs-credentials.log for the URL and admin API key

3. Browse to http://your-public-ip/ for the sample homepage with runtime metadata

4. curl -H 'X-Admin-Key: <key>' http://your-public-ip/api/admin to verify the auth wall

5. Restrict NSG inbound on 80 to trusted IPs

6. Drop your Node.js app into /opt/nodeapp/cloudimg or replace ecosystem.config.js with your own PM2 process definition

7. Tune /etc/nodeapp/cloudimg.env for SESSION_SECRET, ADMIN_API_KEY, custom env vars — systemctl restart cloudimg-app to apply

Support

cloudimg provides 24/7/365 expert technical support. Contact support@cloudimg.co.uk.

Visit www.cloudimg.co.uk/guides/nodejs-22-on-ubuntu-24-04-azure for the full user guide.

Node.js is a registered trademark of the OpenJS Foundation. This image is a repackaged upstream distribution provided by cloudimg. Additional charges apply for build, maintenance, and 24/7 support.

At a glance

https://catalogartifact.azureedge.net/publicartifacts/cloudimg1647283583153.nodejs-22-ubuntu-24-04-10e3c2d0-c96e-4a4b-ac5e-a3a5f66cb825/image5_screenshot01.png
https://catalogartifact.azureedge.net/publicartifacts/cloudimg1647283583153.nodejs-22-ubuntu-24-04-10e3c2d0-c96e-4a4b-ac5e-a3a5f66cb825/image2_screenshot02.png
https://catalogartifact.azureedge.net/publicartifacts/cloudimg1647283583153.nodejs-22-ubuntu-24-04-10e3c2d0-c96e-4a4b-ac5e-a3a5f66cb825/image6_screenshot03.png
https://catalogartifact.azureedge.net/publicartifacts/cloudimg1647283583153.nodejs-22-ubuntu-24-04-10e3c2d0-c96e-4a4b-ac5e-a3a5f66cb825/image3_screenshot04.png
English (United States)
Your Privacy Choices Opt-Out Icon Your Privacy Choices
Consumer Health Privacy Sitemap Contact Us Privacy & Cookies Terms of Use About our ads Manage cookies