Error connecting to socketio in production

realtime isnt wokring on my production instance.

node version is 20.16
ERPNext: v14.x.x-develop () (develop)

Frappe Framework: v15.x.x-develop () (develop)

this is my node-socketio.error.log

internal/modules/cjs/loader.js:818
throw err;
^

Error: Cannot find module ‘node:http’
Require stack:

  • /home/areeb/frappe-bench/apps/frappe/realtime/index.js
  • /home/areeb/frappe-bench/apps/frappe/socketio.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:815:15)
    at Function.Module._load (internal/modules/cjs/loader.js:667:27)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:85:18)
    at Object. (/home/areeb/frappe-bench/apps/frappe/realtime/index.js:2:14)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions…js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Module.require (internal/modules/cjs/loader.js:887:19) {
    code: ‘MODULE_NOT_FOUND’,
    requireStack: [
    ‘/home/areeb/frappe-bench/apps/frappe/realtime/index.js’,
    ‘/home/areeb/frappe-bench/apps/frappe/socketio.js’
    ]
    }

try bench build --apps frappe

sorry that doesnt seem to work

I think the issue might be with the Node.js version. Try running nvm use --lts to switch to the latest LTS version.

my node version is 20.16

i did this but still getting the same