geko
geko

Reputation: 33

How to share a meteor project without an online server

I'm almost finished building my first Meteor app for a university project but can't seem to figure out the best way to submit this. It can't be hosted online as it must be submitted on a USB. How can I ensure that they will be able to run the application/ access my mongoDB data (if this is possible).

Many thanks and apologies for the newbie question, I have been searching but cant figure this out and am running out of time! Thanks!

Upvotes: 3

Views: 81

Answers (2)

Jankapunkt
Jankapunkt

Reputation: 8423

I'm almost finished building my first Meteor app for a university project but can't seem to figure out the best way to submit this.

If that's for a university project your lecturer should have given you some outline on how to submit your project files.

It can't be hosted online as it must be submitted on a USB.

Fine, so you zip / tar / archive your project folder and copy it to the usb. Note, that you should not copy the node_modules folder also not the .meteor/local folders as they will be build against the architecture your lecturer runs his Meteor installation.

How can I ensure that they will be able to run the application

Your lecturer needs to have Meteor installed. Edit: If she has a version different from yours, it will be downloaded automatically.

However, if your lecturer does not have Meteor installed, you may download the installation binaries from the Meteor project website for Windows AND Linux/MacOs and add them to the stick.

If your lecturer does not even know how Meteor works (because you had free choice of technology) you definitely need to add some instructions on how to install and run this app.

If you want to be on the safe side, you should create and add a shell or batch script that installs the npm packages and runs the pp with the right parameters.

Note here, that Linux and MacOs will run your shell scripts but may have not the same programs / commands available.

access my mongoDB data (if this is possible)

To add the mongo data, you can create a mongo dump which then can be imported by your lecturer. However, if your lecturer does not know how to import this, you may also add a documentation on how to import the dump data or also add this functionality to your shell / batch scripts.

Yet another note, try the whole procedure (install, run, import dump etc.) on your own machine in a VM or something to prevent errors in the first place.

If your lecturer is nice and reveals what OS she has you can avoid writing scripts for three platforms.

Good luck.

Upvotes: 2

ghybs
ghybs

Reputation: 53290

Depends on what your examinator is ready to install to start your Meteor project to evaluate it.

The easiest situation for you would be that they can get your project source code, install Meteor and run it, even in development mode (meteor run). As for your DB data, you could make a dump and provide it alongside your source code, or to simplify the examinator's life, simply have your server code to bootstrap the development MongoDB with your data when first run:

// Server code
Meteor.startup(() => {
  if (myCollection.find().count() === 0) {
    myCollection.insert(someBootstrapData);
  }
});

If they will not install Meteor, but can still run a node app, you could build your Meteor project. You will have to provide instructions about how to launch the app and configure it, in particular for the MONGO_URL. Then you will have to provide your DB data in some way…

Now you learn "the hard way" that before betting on a technology, we need to make sure that it fits the purpose up to the end…

If you are lucky enough, they may not require a live app, but can evaluate based on the source code. That would probably still need that they know some basics about Meteor.

Good luck!

Upvotes: 2

Related Questions