-
Notifications
You must be signed in to change notification settings - Fork 366
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Bluemix deploy provider #550
Merged
Merged
Changes from 6 commits
Commits
Show all changes
22 commits
Select commit
Hold shift + click to select a range
7a7196e
Update json version dependency
adamkingit 9716c41
.gitignore coverage/ report directory
adamkingit 3eec119
Add Bluemix deployment provider
adamkingit cdd370a
Add Bluemix deploy provider test coverage
adamkingit 1652849
Update bluemix example
adamkingit b7a419f
Merge branch 'master' into master
adamkingit 1a963f4
Restore json dependency to 1.8.1
adamkingit c44f435
Merge branch 'master' of github.com:adamkingit/dpl
adamkingit 7c5d56d
Rename BluemixCF to BluemixCloudFoundry
69f80f1
Align provider.rb autoload references
6c78cfc
Merge pull request #1 from adamkingit/renameClass
adamkingit a39b4e4
Update json version dependency
adamkingit 2f7c376
.gitignore coverage/ report directory
adamkingit f063087
Add Bluemix deployment provider
adamkingit 722389f
Add Bluemix deploy provider test coverage
adamkingit e92e252
Update bluemix example
adamkingit 5fd6346
Restore json dependency to 1.8.1
adamkingit b937da7
Rename BluemixCF to BluemixCloudFoundry
ef5ed07
Align provider.rb autoload references
f430b3f
Merge branch 'master' of github.com:adamkingit/dpl
76c7217
Merge branch 'master' into master
BanzaiMan 6318619
Merge branch 'master' into master
BanzaiMan File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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 |
---|---|---|
@@ -1,5 +1,6 @@ | ||
Gemfile.lock | ||
.coverage | ||
coverage | ||
.dpl | ||
setuptools*.zip | ||
google_appengine_*.zip | ||
|
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
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 |
---|---|---|
@@ -0,0 +1,22 @@ | ||
module DPL | ||
class Provider | ||
class BluemixCF < CloudFoundry | ||
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
Sorry, something went wrong. |
||
|
||
REGIONS = Hash.new {"api.ng.bluemix.net"}.update( | ||
"eu-gb" => "api.eu-gb.bluemix.net", | ||
"au-syd" => "api.au-syd.bluemix.net" | ||
) | ||
|
||
def set_api | ||
region = options[:region] || "ng" | ||
options[:api] = options[:api] || REGIONS[region] | ||
end | ||
|
||
def check_auth | ||
set_api | ||
super | ||
end | ||
|
||
end | ||
end | ||
end |
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,23 @@ | ||
require 'spec_helper' | ||
require 'dpl/provider/bluemix_cloudfoundry' | ||
|
||
describe DPL::Provider::BluemixCF do | ||
subject :provider do | ||
described_class.new(DummyContext.new, region: 'eu-gb', username: 'Moonpie', | ||
password: 'myexceptionallyaveragepassword', | ||
organization: 'myotherorg', | ||
space: 'inner', | ||
manifest: 'worker-manifest.yml', | ||
skip_ssl_validation: true) | ||
end | ||
|
||
describe "#check_auth" do | ||
example do | ||
expect(provider.context).to receive(:shell).with('wget \'https://cli.run.pivotal.io/stable?release=linux64-binary&source=github\' -qO cf-linux-amd64.tgz && tar -zxvf cf-linux-amd64.tgz && rm cf-linux-amd64.tgz') | ||
expect(provider.context).to receive(:shell).with('./cf api api.eu-gb.bluemix.net --skip-ssl-validation') | ||
expect(provider.context).to receive(:shell).with('./cf login -u Moonpie -p myexceptionallyaveragepassword -o myotherorg -s inner') | ||
provider.check_auth | ||
end | ||
end | ||
|
||
end |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
Sorry, something went wrong.