{"id":23439535,"url":"https://github.com/madwork/chef-chruby-build","last_synced_at":"2025-04-09T19:57:34.092Z","repository":{"id":149507511,"uuid":"18066463","full_name":"madwork/chef-chruby-build","owner":"madwork","description":"Chef cookbook to install chruby and build rubies from source with TCMalloc and LibYAML options on Ubuntu.","archived":false,"fork":false,"pushed_at":"2019-06-26T17:11:58.000Z","size":53,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-09T19:57:29.627Z","etag":null,"topics":["chef","chef-cookbook","chruby","libyaml","ruby","tcmalloc"],"latest_commit_sha":null,"homepage":"https://supermarket.chef.io/cookbooks/chruby-build","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/madwork.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","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":"2014-03-24T15:02:40.000Z","updated_at":"2024-01-22T15:21:36.000Z","dependencies_parsed_at":"2023-07-03T23:20:09.578Z","dependency_job_id":null,"html_url":"https://github.com/madwork/chef-chruby-build","commit_stats":null,"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/madwork%2Fchef-chruby-build","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/madwork%2Fchef-chruby-build/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/madwork%2Fchef-chruby-build/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/madwork%2Fchef-chruby-build/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/madwork","download_url":"https://codeload.github.com/madwork/chef-chruby-build/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248103910,"owners_count":21048245,"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","chef-cookbook","chruby","libyaml","ruby","tcmalloc"],"created_at":"2024-12-23T15:29:34.507Z","updated_at":"2025-04-09T19:57:34.049Z","avatar_url":"https://github.com/madwork.png","language":"Ruby","readme":"# Chruby Build Chef Cookbook\n\n[![Build Status](https://img.shields.io/travis/madwork/chef-chruby-build.svg)](https://travis-ci.org/madwork/chef-chruby-build)\n[![Cookbook Version](https://img.shields.io/cookbook/v/chruby-build.svg)](https://supermarket.chef.io/cookbooks/chruby-build)\n\nChef cookbook to install [chruby](https://github.com/postmodern/chruby) and build rubies from source with [Google Perftools](https://github.com/gperftools/gperftools) / [TCMalloc : Thread-Caching Malloc](http://goog-perftools.sourceforge.net/doc/tcmalloc.html) and [LibYAML](http://pyyaml.org/wiki/LibYAML) options.\n\n## Requirements\n\n#### supports\n\n* `ubuntu \u003e= 12.04`\n\n#### depends\n\n* `ark \u003e= 4.0.0` - [Opscode Cookbook ark](https://supermarket.chef.io/cookbooks/ark)\n\n#### version\n\n* `chef \u003e= 13.4`\n\n## Installation\n\n### From the [Community Site](https://supermarket.chef.io/cookbooks/chruby-build)\n\nUse the knife command:\n\n```sh\n$ knife supermarket install chruby-build\n```\n\n### With [berkshelf](http://berkshelf.com/)\n\nEdit `Berksfile`\n\n    source \"https://supermarket.chef.io\"\n\n    cookbook 'chruby-build', '~\u003e 1.0.2'\n\nInstall the cookbooks you specified in the Berksfile and their dependencies:\n\n```sh\n$ berks install\n```\n\n## Attributes\n\nSee [attributes/default.rb](attributes/default.rb)\n\n## Usage\n\n### Rubies attributes\n\n* `id` - required id and **must be** split by a dash (eg. ruby-2.3.4)\n* `url` - required ruby source\n* `checksum` - optional sha256 package checksum\n* `gems` - optional gems to install\n* `environment` - optional compilation environment variables\n\n#### With node attributes\n\n```json\n{\n  \"ark\": {\n    \"prefix_root\": \"/usr/local/src\"\n  },\n  \"chruby_build\": {\n    \"rubies\": [\n      {\n        \"id\": \"ruby-2.5.3\",\n        \"url\": \"https://cache.ruby-lang.org/pub/ruby/2.5/ruby-2.5.3.tar.gz\",\n        \"checksum\": \"9828d03852c37c20fa333a0264f2490f07338576734d910ee3fd538c9520846c\",\n        \"gems\": [\"bundler 1.17.1\"],\n        \"environment\": {\n          \"ARCHFLAGS\": \"-arch x86_64\",\n          \"CFLAGS\": \"-g -O2\",\n          \"CPPFLAGS\": \"-I/usr/include -I/usr/local/include\"\n        }\n      }\n    ]\n  }\n}\n```\n\n#### With [data bags](http://docs.opscode.com/essentials_data_bags.html)\n\nData bag name **must be** `rubies`\n\n```sh\n$ knife data bag create rubies ruby-2.5.3\n```\n\nEdit data bag `ruby-2.5.3.json`\n\n```json\n{\n  \"id\": \"ruby-2.5.3\",\n  \"url\": \"https://cache.ruby-lang.org/pub/ruby/2.5/ruby-2.5.3.tar.gz\",\n  \"checksum\": \"9828d03852c37c20fa333a0264f2490f07338576734d910ee3fd538c9520846c\",\n  \"gems\": [\"bundler 1.17.1\"],\n  \"environment\": {\n    \"ARCHFLAGS\": \"-arch x86_64\",\n    \"CFLAGS\": \"-g -O2\",\n    \"CPPFLAGS\": \"-I/usr/include -I/usr/local/include\"\n  }\n}\n```\n\nIf you are using knife solo as provisioner, try [knife-solo_data_bag](http://thbishop.com/knife-solo_data_bag/).\n\nData bags have **higher** precedence.\n\n### Recipes\n\n#### chruby-build::default\n\nThis recipe only installs chruby.\n\nJust include `chruby-build::default` in your node's `run_list`:\n\n```json\n{\n  \"name\":\"my_node\",\n  \"run_list\": [\n    \"recipe[chruby-build::default]\"\n  ]\n}\n```\n\n#### chruby-build::rubies\n\nThis recipe installs chruby and compile rubies from source.\n\nJust include `chruby-build::rubies` in your node's `run_list`:\n\n```json\n{\n  \"name\":\"my_node\",\n  \"run_list\": [\n    \"recipe[chruby-build::rubies]\"\n  ]\n}\n```\n\n## Development\n\n#### Dependencies\n\n* [bundler](https://bundler.io/)\n* [vagrant](https://www.vagrantup.com/)\n* [kitchen-vagrant](https://github.com/test-kitchen/kitchen-vagrant)\n* [berkshelf](https://docs.chef.io/berkshelf.html)\n* [serverspec](https://serverspec.org/)\n\n#### Installation\n\nEnsure the gem dependencies are installed:\n\n```sh\n$ bundle install\n$ bundle exec berks install\n```\n\nRunning unit tests:\n\n```sh\n$ bundle exec rspec\n```\n\nRunning integration tests:\n\n```sh\n$ bundle exec kitchen test rubies-data-bags-ubuntu-1404\n```\n\nDifferent test suites are available:\n\n```sh\n$ bundle exec kitchen list\n$ bundle exec kitchen setup default-ubuntu-1404\n$ bundle exec kitchen verify default-ubuntu-1404\n$ bundle exec kitchen destroy default-ubuntu-1404\n```\n\n## Contributing\n\n1. Fork the repository on Github\n2. Create a named feature branch (like `add_component_x`)\n3. Write your change\n4. Write tests for your change (if applicable)\n5. Run the tests, ensuring they all pass\n6. Submit a Pull Request using Github\n\n## License\n\nWritten by [Vincent Durand](https://github.com/madwork).\n\nReleased under the terms of the MIT License. For further information, please see the file [LICENSE.txt](LICENSE.txt).\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmadwork%2Fchef-chruby-build","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmadwork%2Fchef-chruby-build","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmadwork%2Fchef-chruby-build/lists"}