Deploying Meteor App

Newbie here, forgive me for noob questions. Have just taken over a new role and been left with a couple of meteor app files, an app tarball and a db tarball.

Just wondering if there is a way to deploy and test this, have tried setting up a Ubuntu 14.04 server with npm 0.12 , nginx and mongodb installed. Have also gone through various guides online but can’t seem to figure out what to do.

The app seems like a web app, it contains a server folder and a web.browser folder. I tried running npm install on the server folder, but there is no main.js file just boot.js file.

Any help/guide on how to proceed with this would be appreciated, am just trying to get this app up and running, thanks.

If that’s a standard Meteor bundle, the top level directory (bundle/) will include a README outlining the broad-brush installation requirements.

This is the README from a 1.6 build:

This is a Meteor application bundle. It has only one external dependency:
Node.js v8.9.3. To run the application:

  $ (cd programs/server && npm install)
  $ export MONGO_URL='mongodb://user:password@host:port/databasename'
  $ export ROOT_URL=''
  $ export MAIL_URL='smtp://user:password@mailhost:port/'
  $ node main.js

Use the PORT environment variable to set the port where the
application will listen. The default is 80, but that will require
root on most systems.

Find out more about Meteor at

The version of node.js to use is in the first paragraph - your node.js version sounds like it will be different (you said npm 0.12 - did you mean node.js 0.12?). You should use the version of npm which was used with your version of node.js.

Edit: Are you installing on the same architecture as the build?

By default, your application is bundled for your current architecture. This may cause difficulties if your app contains binary code due to, for example, npm packages. You can try to override that behavior with the --architecture flag.

1 Like

Hi Rob, thanks for replying.

Yes, i did read about the README part but unfortunately it doesn’t look like a standard Meteor bundle, the bundle/ directory does not exist. When i uncompress the app.tar.gz it just has an app directory with server and web.browser directory and further files in there.

Yes i meant node.js 0.12 , and npm is the version that came with it.

There is no main.js file, what does this mean?

Apologies for the bluntness am trying to work this all out, appreciate your input in this.

1 Like

It sounds like it may be missing the important stuff. My top level bundle/ directory contains main.js programs/ README server/ star.json.

The server/ and web.browser folders you mention are underneath programs/ in my build. There are boot.js files in both bundle/programs/server/ and bundle/programs/web.browser/.

It looks like you have a tarball of bundle/programs/.

However, main.js is pretty simple (I don’t have one from 0.12 days):

process.argv.splice(2, 0, 'program.json');
process.chdir(require('path').join(__dirname, 'programs', 'server'));

star.json contains build info:

  "format": "site-archive-pre1",
  "builtBy": "Meteor METEOR@",
  "programs": [
      "name": "web.browser",
      "arch": "web.browser",
      "path": "programs/web.browser/program.json"
      "name": "server",
      "arch": "os",
      "path": "programs/server/boot.js"
  "meteorRelease": "METEOR@",
  "nodeVersion": "8.9.3",
  "npmVersion": "5.5.1"
1 Like

Thank you very much again for that info. It helps a lot especially the structure of your build.

It does look like important stuff is missing, am getting a clearer picture now.

Thanks again, i guess without the main.js and bundle/ directory it is not possible to do much with this?

1 Like
  • The bundle/ directory is just a wrapper - recreate it.
  • Inside the new bundle/ create server/ and programs/ directories.
  • Inside the new bundle/ create main.js and star.json.
  • Copy my main.js into yours.
  • Hack my star.json into yours (change versions, etc.)
  • My server/ folder is empty, so you could try that.
  • Extract your tarball into programs/.

You now have a potentially valid bundle.

Good luck!

1 Like

Was just about to do something similar but you straightened it out there for me ! Thanks again if this works i will owe you a lifetime of beer!

Cheers Rob and god bless.

1 Like

Haha - you’re welcome.

The only suspect bit (apart from everything) is probably the empty server/ folder. I’ve never studied the build contents before, so I don’t know what that means (I do have server code in my app)!

Edit: Ah - that’s populated following step 1 in the README.

1 Like