{"id":20811319,"url":"https://github.com/express42/ruby_lwrp","last_synced_at":"2026-01-05T14:10:39.324Z","repository":{"id":66323624,"uuid":"9746365","full_name":"express42/ruby_lwrp","owner":"express42","description":"Express 42 ruby installer cookbook","archived":false,"fork":false,"pushed_at":"2017-05-10T10:45:45.000Z","size":49,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":25,"default_branch":"master","last_synced_at":"2025-01-28T17:17:07.109Z","etag":null,"topics":["chef","cookbooks"],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/express42.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2013-04-29T11:10:00.000Z","updated_at":"2024-05-11T21:17:10.000Z","dependencies_parsed_at":"2023-02-25T08:15:16.392Z","dependency_job_id":null,"html_url":"https://github.com/express42/ruby_lwrp","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/express42%2Fruby_lwrp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/express42%2Fruby_lwrp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/express42%2Fruby_lwrp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/express42%2Fruby_lwrp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/express42","download_url":"https://codeload.github.com/express42/ruby_lwrp/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245090866,"owners_count":20559296,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["chef","cookbooks"],"created_at":"2024-11-17T20:40:09.224Z","updated_at":"2026-01-05T14:10:39.318Z","avatar_url":"https://github.com/express42.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Description\n\n[![Cookbook Version](http://img.shields.io/cookbook/v/ruby_lwrp.svg)]('http://img.shields.io/cookbook/v/ruby\\_lwrp.svg)\n[![Code Climate](https://codeclimate.com/github/express42-cookbooks/ruby_lwrp/badges/gpa.svg)](https://codeclimate.com/github/express42-cookbooks/ruby_lwrp)\n[![Build Status](https://travis-ci.org/express42/ruby_lwrp.svg?branch=master)](https://travis-ci.org/express42/ruby_lwrp)\n\nCookbook `ruby_lwrp` builds various versions of ruby and installs them to `/opt/rubies`. It uses [ruby-build](https://github.com/sstephenson/ruby-build) to build and install ruby and [chruby](https://github.com/postmodern/chruby) for switching between installed ruby versions.\n\n# Requirements\n\n## Platform:\n\n* Debian\n* Ubuntu\n\n## Cookbooks:\n\n*No dependencies defined*\n\n# Attributes\n\n* `node['ruby']['chruby']['install_path']` -  Defaults to `\"/opt/chruby\"`.\n* `node['ruby']['chruby']['home_prefix']` -  Defaults to `\"/home\"`.\n* `node['ruby']['chruby']['git_url']` -  Defaults to `\"git://github.com/postmodern/chruby.git\"`.\n* `node['ruby']['chruby']['git_ref']` -  Defaults to `\"master\"`.\n* `node['ruby']['chruby']['install_pkgs']` -  Defaults to `\"%w(make git-core)\"`.\n* `node['ruby']['ruby_build']['install_path']` -  Defaults to `\"/opt/ruby-build\"`.\n* `node['ruby']['ruby_build']['git_url']` -  Defaults to `\"git://github.com/sstephenson/ruby-build.git\"`.\n* `node['ruby']['ruby_build']['git_ref']` -  Defaults to `\"master\"`.\n* `node['ruby']['ruby_build']['install_pkgs']` -  Defaults to `\"%w(build-essential bison openssl libreadline6 libreadline6-dev zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-0 libsqlite3-dev sqlite3 libxml2-dev libxslt1-dev autoconf libc6-dev ssl-cert subversion git-core libffi-dev)\"`.\n* `node['ruby']['ruby_build']['tmp_dir_path']` - Defaults to '\"/tmp\"'. It sets TMPDIR for ruby-build.\n\n# Recipes\n\n* ruby_lwrp::default - Includes `ruby_build` and `chruby` recipes.\n* ruby_lwrp::chruby - Installs the Chruby to `/opt/chruby` and prepares Chef to `ruby_set` the LWRP.\n* ruby_lwrp::ruby_build - Installs the ruby-build to `/opt/ruby-build` and prepares Chef to use `ruby_install` LWRP.\n\n# LWRP\n\n## ruby_install\n### Actions\n- **install:** Builds and installs ruby, includes chruby functions via `/etc/profile.d/`.\n\n### Attribute Parameters\n- **definition:** This attribute defines ruby version. Should be in ruby-build definition list;\n- **prefix:** Set install prefix for ruby-build, default is `/opt/rubies`;\n- **build_ruby:** Build ruby from sources via ruby-build. `True` by default. If `False`, try to install system ruby package.\n\n## ruby_set\n### Actions\n- **set:** Install chruby_auto helper to user's `.profile` and create `.rubyversion` in user's home directory.\n\n### Attribute Parameters\n- **definition:** Name attribute, define ruby version. Should be in ruby-build definition list;\n- **username:** Target user;\n- **install_bundler:** If `true`, bundler will be installed. Default is `true`.\n\n\n# Usage\n\nYou must include `recipe[ruby_lwrp::default]` to your run list or via `include_recipe`. If you don't want to build ruby or use chruby, you may use `recipe[ruby_lwrp::ruby_build]` or `recipe[ruby_lwrp::chruby]` recipes.\n\n## Example of ruby 1.9.3-p392 setup:\n\n```\ninclude_recipe 'ruby_lwrp::default'\n\nruby_install '1.9.3-p392' do\n  action :install\nend\nruby_set '1.9.3-p392' do\n  action :set\n  username 'alice'\nend\n```\n\nSee fixture cookbook in `tests/fixtures/cookbooks`.\n\n\n# License and Maintainer\n\nMaintainer:: LLC Express 42 (\u003ccookbooks@express42.com\u003e)\n\nLicense:: MIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fexpress42%2Fruby_lwrp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fexpress42%2Fruby_lwrp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fexpress42%2Fruby_lwrp/lists"}