Created
August 24, 2012 20:25
-
-
Save grimen/3455253 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
require 'rubygems' | |
require 'pow_proxy' | |
# 1. cd <this_node_project> | |
# 2. gem install powder pow_proxy | |
# 3. echo <this_file> > ./config.ru | |
# 4. NODE_PORT=8888 npm start | |
# 5. powder link hejhopp | |
# 6. open hejhopp.dev | |
# | |
# ...eller lägg in en hejhopp.com manuellt i /etc/hosts (pow kör med .dev) | |
domain = `cat ./.powder` | |
domain = domain ? "#{domain}.dev" : "hejhopp.com" | |
map "/some/path/i/want/override/locally.js" do | |
run PowProxy.new(:host => '127.0.0.1', :port => 8888) # custom | |
end | |
map '/' do | |
run PowProxy.new(:host => domain, :port => 80) # production | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment