In Progress [CPANEL-32218] Any way to update Node.js version?

dtcompoer

Registered
Jul 15, 2020
1
0
1
Utah, USA
cPanel Access Level
Root Administrator
I'm currently trying to install my first Node.JS app through the user inteface and getting the following error message:

Code:
App 1328642 output: internal/modules/cjs/loader.js:981
App 1328642 output:   throw new ERR_REQUIRE_ESM(filename);
App 1328642 output:   ^
App 1328642 output:
App 1328642 output: Error [ERR_REQUIRE_ESM]: Must use import to load ES Module: /home/davidha1/apps/comment-system/app.mjs
App 1328642 output:     at Object.Module._extensions..mjs (internal/modules/cjs/loader.js:981:9)
App 1328642 output:     at Module.load (internal/modules/cjs/loader.js:790:32)
App 1328642 output:     at Function.Module._load (internal/modules/cjs/loader.js:703:12)
App 1328642 output:     at Module.require (internal/modules/cjs/loader.js:830:19)
App 1328642 output:     at Module.require (/opt/passenger-5.3.7-9.el7.cloudlinux/src/helper-scripts/node-loader.js:80:25)
App 1328642 output:     at require (internal/modules/cjs/helpers.js:68:18)
App 1328642 output:     at loadApplication (/opt/passenger-5.3.7-9.el7.cloudlinux/src/helper-scripts/node-loader.js:243:2)
App 1328642 output:     at setupEnvironment (/opt/passenger-5.3.7-9.el7.cloudlinux/src/helper-scripts/node-loader.js:214:2)
App 1328642 output:     at Object.<anonymous> (/opt/passenger-5.3.7-9.el7.cloudlinux/src/helper-scripts/node-loader.js:133:1)
App 1328642 output:     at Module._compile (internal/modules/cjs/loader.js:936:30)
After some searching It seems to be an issue with Node.JS. I used version 14.4 to make this app, and the latest version available through the ui is 12.9.

I'd like to know if there is a way to update it through the CLI or other means. I have tried:

1. to include "node":"14.4.0" in my package.json file,
2. added "type": "module" to package.json
3. attempted to get to node to run -i through the ssh access and terminal.

Thanks.
David
 

cPRex

Jurassic Moderator
Staff member
Oct 19, 2014
4,225
532
273
cPanel Access Level
Root Administrator
Alright, I heard back from the team today and while they are aware of the request it just hasn't received enough requests to get action on it yet. I can say that we are regularly adding updates to version 10, as the recent EasyApache updates moved to 10.23.2.

I'm sorry I don't have better news on this at this point.
 

hbouma

Well-Known Member
Jun 8, 2002
60
0
306
Alright, I heard back from the team today and while they are aware of the request it just hasn't received enough requests to get action on it yet. I can say that we are regularly adding updates to version 10, as the recent EasyApache updates moved to 10.23.2.
v10 reaches EOL in 2 months so I'm a bit surprised that still no guidance available yet. Will the next update include supporting v12 or v14 or both? If requests are needed to take action on an existing case issue, shouldn't there be a feature request opened to make it easier for cPanel to get feedback on it? It's kind of hard to provide feedback on an internal issue. Or should someone open one now?
 

tism77leo

Registered
Feb 24, 2021
1
1
3
Bulgaria
cPanel Access Level
Root Administrator
Since the lack of progress is at least partly due to: "hasn't received enough requests to get action on it yet" and I can't find a feature request issue as well, I would just add my voice to the choir here for v12 support to be supported, our applications now require a minimum of Node v12 to be installed which is obviously a problem.
 
  • Like
Reactions: cPRex