/rvm_sl

Super light rvm Chef cookbook

Primary LanguageRuby

Cookbook Version Build Status Code Climate Coverage Status Dependency Status

rvm_sl Cookbook

Manages per-user RVMs and manages installed Rubies.

Requirements

Platforms

  • Ubuntu 14.04 LTS

Chef

  • Chef 12.2.0

packages

  • rvm_sl::user_install - User installation of rvm

Attributes

rvm_sl::user_install

See attributes/user_install.rb for default values.

  • node['rvm']['keyserver'] - Key to import from key server
  • node['rvm']['rcev-keys'] - Import the keys with the given key IDs from a keyserver
  • node['rvm']['user']['name'] - The user name for rvm user install
  • node['rvm']['user']['home'] - The home of the user

Resources

Example install ruby 2.2.3 as default for vagrant user:

rvm_rubies 'ruby-2.2.3' do
  default true
  home '/home/vagrant'
  user_name 'vagrant'
end

Example install bundler gem for user install ruby 2.2.3:

rvm_gem 'bundler' do
  home '/home/vagrant'
  ruby_version 'ruby-2.2.3'
  user_name 'vagrant'
end

Usage

rvm_sl::user_install

Just include rvm_sl::user_install in your node's run_list:

{
  "name":"my_node",
  "run_list": [
    "recipe[rvm_sl::user_install]"
  ]
}

Sharing

knife cookbook site share "rvm_sl" "Package Management"

Testing

Before running kitchen test:

# vagrant box matching `.kitchen.yml` platform driver box
vagrant box add ubuntu-14.04 https://github.com/kraksoft/vagrant-box-ubuntu/releases/download/14.04/ubuntu-14.04-amd64.box

Contributing

  1. Fork the repository on Github
  2. Create a named feature branch (like add_component_x)
  3. Write your change
  4. Write tests for your change (if applicable)
  5. Run the tests, ensuring they all pass
  6. Submit a Pull Request using Github

License and Authors

Authors: David Saenz Tagarro