I'm trying to figure out why vagrant w/chef-solo + chef-rvm isn't working for me. Here's how I think it's supposed to work:
- You tell chef where chef-solo is installed on the vagrant image
- The rvm:vagrant recipe creates a wrapper script, also called chef-solo, that does this: a. set an environment variable overriding the current ruby to "system" b. calls chef-solo as specified in the attributes c. it goes on the path before the real chef-solo does
- the rvm:system recipe installs rvm and your specified ruby system-wide
- Now, the next time you do a
vagrant up
, chef-solo (which is now actually the wrapper script) will still work because it's using the system-installed ruby, which has access to the chef-solo gem, as opposed to your newly installed Ruby, which doesn't.