Skip to content

datarockets/infrastructure-rails

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

50 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Ansible: Ruby on Rails Server (Ubuntu 16.x)

Use this ansible playbook to setup a fresh server with the following components:

  • Nginx
  • Puma App Server
  • Certbot (Let's Encrypt)
  • PostgreSQL
  • Memcached
  • Redis
  • Sidekiq
  • Monit (to keep Puma and Sidekiq runnig)
  • Elasticsearch
  • ruby-install
  • rbenv
  • Directories to deploy Rails with Capistrano and Puma App Server (see below)
  • Swapfile (useful for small DO instances)
  • Tools (tmux, vim, htop, git, wget, curl etc.)
  • DB backup using backup gem
  • Logrotate

Install Ansible

Brew

brew install ansible

APT

apt-get install ansible

Prerequisites & Config

  1. Copy hosts.example to hosts and modify the contents.

  2. Copy group_vars/all.example to group_vars/all and modify the contentes.

    There are a bunch of things you can set in group_vars/all. Don't forget to add your host address to hosts.

cp hosts.example hosts
cp group_vars/all.example group_vars/all

Install Playbook

Run ansible-playbook site.yml -i hosts.

Rails Setup

For setuping Rails application use Blueprint Gem

Feedback

Feel free to send feedback or report problems via GitHub issues!

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •