Step to setup a Meteor Server on Linux


Node is our javascript server

#install EPEL repo if you don't have it already
yum install
# Install Node.js
sudo yum install nodejs npm --enablerepo=epel


Forever will start our server and make sure it keeps running.

sudo npm install -g forever


Mongo will be our database server

echo [mongodb] > /etc/yum.repos.d/mongodb.repo
echo name=MongoDB Repository >> /etc/yum.repos.d/mongodb.repo
echo baseurl= >> /etc/yum.repos.d/mongodb.repo
echo gpgcheck=0 >> /etc/yum.repos.d/mongodb.repo
echo enabled=1 >> /etc/yum.repos.d/mongodb.repo
yum update -y
yum install mongodb-org
service mongod start
chkconfig mongod on


curl | /bin/sh

Create Git Repo on Server

mkdir example.git
cd example.git
git --bare init
cd ..

Add repo to local Git project

git remote add origin ssh://user@
git push origin master

Clone the project on the server

git clone example.git

Setup bundler

echo cd example >
echo git pull >>
echo meteor bundle ../bundle.tgz >>
echo cd .. >>
echo sudo forever stop bundle/main.js >>
echo tar -zxvf bundle.tgz >>
echo PORT=80 MONGO_URL=mongodb://localhost:27017/example ROOT_URL=http://localhost forever start bundle/main.js >>
chmod +x ./

Start it up!


Share This:

Leave a Reply

Your email address will not be published. Required fields are marked *