Skip to content
This repository has been archived by the owner on Mar 24, 2022. It is now read-only.

Commit

Permalink
Added ability to target any space
Browse files Browse the repository at this point in the history
  • Loading branch information
Pinwheeler committed Mar 30, 2015
1 parent c77a942 commit e88123b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
4 changes: 4 additions & 0 deletions lib/cf_authenticator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ def initialize

def authenticate_with(username,password,org,space)
auth_result = `cf auth #{username} #{password}`
if !auth_result
puts "Could not load the Cloud Foundry Command Line Interface\nGet it at http://docs.cloudfoundry.org/devguide/installcf/install-go-cli.html"
exit
end
if auth_result.include?("FAILED")
puts 'Authentication failed, exiting'
exit
Expand Down
7 changes: 1 addition & 6 deletions lib/cf_deploy.rb
Original file line number Diff line number Diff line change
Expand Up @@ -66,12 +66,7 @@ def wait_for_input_with(question)

def push_to_cf
puts 'pushing to Cloud Foundry...'
if @actual_env === 'project-monitor-staging'
puts `cf push project-monitor-staging -f config/cf/manifest-staging.yml`
end
if @actual_env === 'project-monitor-production'
puts `cf push project-monitor-production -f config/cf/manifest-production.yml`
end
puts `cf push #{@actual_env}`
puts `cf logout`
end

Expand Down

0 comments on commit e88123b

Please sign in to comment.