Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
bb5db2f
commit d3fe6ae
Showing
5 changed files
with
51 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,4 +2,4 @@ source "http://rubygems.org" | |
gem "rack" | ||
gem "sinatra" | ||
gem "haml" | ||
gem "less" | ||
gem "less" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,33 @@ | ||
h1. RVM::FW Edition | ||
# RVM::FW Edition | ||
|
||
RVM::FW is meant to be a simple Sinatra application that you can easily deploy on an intranet server and enable quick and easy access to install multiple ruby versions side-by-side the way RVM does at home. | ||
|
||
## Setting up RVM::FW | ||
|
||
h2. Random self-notes: | ||
NOTE: This will eventually work, right now we are still working on the boot:strap rake task. If you want to help feel free to pitch in by looking at the [related issue](http://github.com/stevenhaddox/rvm_fw/issues). | ||
Once you have RVM::FW downloaded locally you need to download the rubies that you want to serve (probably before you deploy if you're behind a firewall). In order to do this simply run: | ||
|
||
h3. RVM install workflow | ||
$ rake boot:strap | ||
|
||
NOTE: This will eventually become [dynamic](), but in the interim you need to modify the views/db.txt file to hardcode your final deployed URL instead of 'rvm-fw.local'. | ||
|
||
## Deploy | ||
|
||
The application comes pre-configured to work with Phusion Passenger easily. Overall it's just a simple Sinatra application so feel free to customize as needed and push it all to your server (just make sure the ruby installs are included in your deploy). | ||
|
||
## Configuring RVM to work with RVM::FW | ||
|
||
Just visit: http://[your-server]/db to get a plain-text file that your users need to copy and paste into: ~/.rvm/config/user. This file overrides the defaults built into RVM's ~/.rvm/config/db and will point it to your RVM::FW instance to download it's rubies. | ||
|
||
# I could benefit from RVM::FW - How do I help? | ||
|
||
Fork away and start hacking on any of our [open issues](http://github.com/stevenhaddox/rvm_fw/issues). | ||
|
||
|
||
|
||
## Random miscellaneous self-notes: | ||
|
||
### RVM install workflow | ||
|
||
- Downloads into .rvm/archives | ||
- Extracts downloads into .rvm/src |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# import all .rake files under lib/tasks | ||
Dir.glob('lib/tasks/*.rake').each { |r| import r } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,20 @@ | ||
require 'yaml' | ||
|
||
namespace :boot do | ||
task :strap do | ||
@rubies = | ||
puts "i like boots!" | ||
@rubies = YAML::load_file('config/rubies.yml') | ||
@rubies.each do |ruby, params| | ||
puts "---" | ||
puts "Starting #{ruby}" | ||
|
||
#create path from params[:path_prefix] | ||
puts "Creating directory public/rubies/#{params[:path_prefix]}" | ||
FileUtils.mkdir_p "public/rubies/#{params[:path_prefix]}" | ||
|
||
#download each ruby from params[:url] | ||
puts "Downloading #{ruby}..." | ||
# wget #{params[:url]} public/rubies/#{params[:path_prefix]} | ||
puts "Completed download" | ||
end | ||
end | ||
end | ||
|
||
# yaml_obj = YAML::dump( test_obj ) | ||
# # -> --- | ||
# - dogs | ||
# - cats | ||
# - badgers | ||
# ruby_obj = YAML::load( yaml_obj ) | ||
# # => ["dogs", "cats", "badgers"] | ||
# |