Azure App Service Linux node stack: outdated npm version

Christopher Barless 15 Reputation points
2023-02-17T21:54:18.3133333+00:00

Hello,

I have an Azure App Service web app running the NODE|18-lts Linux runtime stack.

I'm doing a zip deploy of a node app and my server code ( Remix app server ) evidently uses some syntax that requires npm >= 7 to run.

However, the app service container only seems to use npm 6.14.15, regardless of the node runtime version specified in the config.

The container will utilize the node and npm executables at /usr/local/bin .

The node executable changes versions along with the config, but the npm version stays at 6.14.15.

If I deploy my app using the service as-is, my startup command gives me a cryptic error:

npm start
npm info it worked if it ends with ok
npm info using npm@6.14.15
npm info using node@v18.12.1
npm info lifecycle 
Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
8,930 questions
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.