Custom deployment problem: Cannot find module '/opt/tutor/bundle/programs/server/main.js'


#1

Meteor: 1.4.0.1
Node: 4.4.7
OS: Ubuntu 16.04.

According to the documentation a custom deployment should be started with
MONGO_URL=mongodb://localhost:27017/myapp ROOT_URL=http://my-app.com node main.js

Doing this on the server gives
Error: Cannot find module '/opt/tutor/bundle/programs/server/main.js’
at Function.Module._resolveFilename (module.js:325:15)
at Function.Module._load (module.js:276:25)
at Function.Module.runMain (module.js:441:10)
at startup (node.js:139:18)
at node.js:968:3

In the bundle no file main.js exists so trying instead
MONGO_URL=mongodb://localhost:27017/myapp ROOT_URL=http://my-app.com node boot.js results in

Error: Cannot find module 'fibers'
    at Function.Module._resolveFilename (module.js:325:15)
    at Function.Module._load (module.js:276:25)
    at Module.require (module.js:353:17)
    at require (internal/module.js:12:17)
    at Object.<anonymous> (/opt/tutor/bundle/programs/server/boot.js:1:75)
    at Module._compile (module.js:409:26)
    at Object.Module._extensions..js (module.js:416:10)
    at Module.load (module.js:343:32)
    at Function.Module._load (module.js:300:12)
    at Function.Module.runMain (module.js:441:10)

Any ideas?


#2

Have you run (cd programs/server && npm install) before trying to start the app?


#3

You are right, thank you.


#4

But don’t work for me.
don’t show anything for along time when running


#5

Now work fine for me
Linke