Provisioning Rails Servers with Ansible

  • 287 views
Uploaded on

 

More in: Software , Technology
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
No Downloads

Views

Total Views
287
On Slideshare
0
From Embeds
0
Number of Embeds
2

Actions

Shares
Downloads
1
Comments
0
Likes
1

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide

Transcript

  • 1. Provisioning Rails Servers with Ansible Radamanthus Batnag @radamanthus https://github.com/radamanthus/
  • 2. This talk is about • Tasks in provisioning a Rails server • Ansible • My cool open-source ansible-rails playbook • Life in general
  • 3. New Server? No problem! http://www.animschoolblog.com/2012/12/new-server-for-animschoolcom.html
  • 4. No problem! • Get the latest OS packages • Disable all ports except port 22 • Harden sysctl settings • Add ssh keys for deploy user • Disable root ssh
  • 5. No problem… • Add Brightbox PPA • Install Ruby • Install Bundler
  • 6. No problem? • Add PostgreSQL PPA • Create the deploy postgres user • Create database.yml with the correct password • Create the app database
  • 7. Hmmm… • Add Nginx PPA • Install Nginx • Remove default site • upload myapp.conf Nginx config file
  • 8. Aaargh • Install the Puma gem • add puma to /etc/init.d/ • Prepare the puma pid directory • add app to /etc/puma.conf • create monitrc for puma
  • 9. In the old days, we had a recipe…
  • 10. https://www.digitalocean.com/community/articles/how-to-install-rails-and-nginx-with-passenger-on-ubuntu
  • 11. These days, we have Ansible Puppet Chef
  • 12. Demo
  • 13. https://github.com/ radamanthus/ansible-rails Start Here!
  • 14. Key Ansible Concepts • Variables • Includes • Templates • Files • Roles
  • 15. Walkthrough
  • 16. Resources • http://docs.ansible.com • http://lattejed.com/first-five-and-a-half-minutes-on-a- server-with-ansible • http://guides.spreecommerce.com/developer/ansible- ubuntu.html • https://github.com/radar/ansible-rails-app • https://github.com/radamanthus/ansible-rails
  • 17. Thank You