Question

Why is my upstart file not starting my MeteorJS app?

I am on Ubuntu 14.04 and I have an upstart file angular-meteor.conf with the following:

# upstart service file at /etc/init/angular-meteor.conf
description "Meteor.js (NodeJS) application"

# When to start the service
start on runlevel [2345]

# When to stop the service
stop on shutdown

# Automatically restart process if crashed
respawn

# Let upstart know the process will detach itself to the background
expect fork

# start meteor
exec meteor

This is not working, I have tried a few variations eg. http://stackoverflow.com/questions/15657071/how-to-run-meteor-on-startup-on-ubuntu-server

Anyone know why it wouldn’t be working? I know that it is starting at least.

Show comments

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

Add the following lines to your upstart script:

setuid user to run as
setgid group to run as, usually the same as the user
chdir /path/to/meteor_app

Then try starting it. Does that work? If not, take a look at the log file and see if there are any errors:

sudo tail /var/log/upstart/angular-meteor.log

This comment has been deleted