Ansible deployment scripts that help you quickly set up a production-ready meteor website on either a Ubuntu host or a Local Vagrant instance.
I'm actively working on a new version of easy-deploy. The README file below no longer applies. Please check back soon.
- VirtualBox
- Vagrant
- Ansible
You may want to use easy-meteor-deploy if
- You need isolation for your different components so that they may be ready for horizontal scalability in the future
- You need to host multiple Meteor apps in one server without them interfering with each other
- You need Nginx
- You need customized components, such as Redis, RabbitMQ, Memcached, etc.
- You want a practice environment (e.g. Vagrant) to test your deployment
- Basically, you want complete control over your remote machine environment in an organized and declarative fashion
- You have a git repository for your Meteor app and the app is in root folder of your repository.
- Your remote server runs Ubuntu 14.04. (Other versions of Ubuntu might work but are untested.)
- Fork this repo into
https://github.com/__yourname__/easy-meteor-deploy.git
- Under your Meteor project repository, create a git subtree
git remote add easy https://github.com/__yourname__/easy-meteor-deploy.git
git subtree add --prefix=.deploy easy master --squash
You will find a new .deploy
under your project.
- Make directory
mkdir .deploy_vars
- Copy
.deploy/vars/main.example.yml
as.deploy_vars/main.yml
- In
/vars/main.yml
, changeapp_name
,repo_url
anddomain_name
to your own values. - Copy
server-inventories/remote_inveontory.example
as./deploy_vars/inventories/master
, and replaceexample.org
inremote_inveontory
with your own domain - Copy
vars/server-addresses/master.example.yml
as./deploy_vars/server_addresses/master.yml
, and replaceserver.public.address
and ``server.internal.port` with your values - Make sure your SSH key is properly set up to access your remote host
- Run the following script to set up software required to run your Meteor app and deploy your app:
cd .deploy
ENV=master ./deploy.sh
cd .deploy
vagrant up
ENV=vagrant ./deploy.sh
git fetch easy
git merge --squash -s subtree --no-commit easy/master
- Make a commit with
git commit
that changes your.deploy
folder - Push back to your fork by running
git subtree push --prefix .deploy easy delpoy --squash
- Make a pull request from your fork
- Oplog tailing (coming soon)
- Dockerize Meteor/node app (for better isolation)
- Build apps in a specified environment (Linux ==> Linux)
Work derived from westonplatter's example_meteor_deploy.