fog-openstack | Fog for OpenStack Platform | Infrastructure Automation library
kandi X-RAY | fog-openstack Summary
kandi X-RAY | fog-openstack Summary
This is the plugin Gem to talk to OpenStack clouds via fog. The main maintainers for the OpenStack sections are @dhague, @Ladas, @seanhandley, @mdarby and @jjasghar. Please send CC them on pull requests.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of fog-openstack
fog-openstack Key Features
fog-openstack Examples and Code Snippets
compute = Fog::OpenStack::Compute.new(@connection_params)
p compute.images
# =>
# ]
# >
p compute.flavors
# => ,
# ,
# ...
flavor = compute.flavors[0]
image = compute.images[0]
instance = compute.s
identity = Fog::OpenStack::Identity.new(@connection_params)
identity.domains
# =>
# ]
# >
identity.projects
# => ,
# ...
# ]
# On Keystone V2
identity.tenants
# =>
identity.users
# =>
project_id = iden
image = Fog::OpenStack::Image.new(@connection_params)
image_out = File.open("/tmp/cirros-image-download", 'wb')
streamer = lambda do |chunk, _, _|
image_out.write chunk
end
image.download_image(image.images.first.id, response_block: streamer)
Community Discussions
Trending Discussions on fog-openstack
QUESTION
I am working through the Ruby on Rails Tutorial (Rails5) by Michael Hartl in the AWS Cloud9 environment. I'm finishing chapter 11 now. (new to programming as well)
It appears I have broken something related to the Rails (or Ruby) system. I am no longer able to start the Rails server, test or console.
The error message I get usually starts with this, which I have not had any luck finding much information on here or via Google. ovirt-engine-sdk -v '4.2.3'
...ANSWER
Answered 2018-Apr-09 at 13:04So I was able to fix this by:
Installing libcurl developer version:
sudo yum install libcurl libcurl-devel
Once that was complete I ran bundle update which now made it further in the install - to fail at this point Installing pg 0.20.0 with native extensions Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
Running
sudo yum install postgresql-devel
resolved the pg 0.20.0 issue and I am now able to complete the bundle update and rails seems to be working again.Rails server had an issue booting after all of this. This command got it working again:
bin/rails db:migrate RAILS_ENV=development
After that the environment and rails all seems to be working fine again.
QUESTION
UPDATE 20180209: I created a new dummy app with what comes with the initial Rails 5.1.4 install (which includes minitest 5.11.3) and tests completed without issue. Going to continue to experiment with the gemfile to see if I can't narrow down what in the world may be causing this problem...
If you have any ideas or pointers, please let me know!
I recently started testing a new portion of my codebase and I've discovered a very critical issue. For whatever reason, every test is now throwing the titled error. Looking into the trace, it looks like for some reason the quoted name/title of my tests is causing a problem. Going back and running tests that I know were passing (though admittedly on earlier gem versions) unfortunately yields the same results, as shown below with the User model.
I've tried everything I know to do, including completely removing and reinstalling RVM, Rails, and Ruby. I've even tried versioning Minitest to an earlier build, like 10.5.3, but still no luck. I've spent most of the day trying to fix this; I'm at my wits end and desperately need help! Though I've learned the hard way that I now need to explicitly version protect ALL of my gems ;)
Thank you in advance! Please let me know if you need me to include any more files/snippets. I'll do my best to reply to any questions as my schedule allows, hopefully within 24 hours.
Returned trace:
E
Error: UserTest#test_should_be_valid: TypeError: no implicit conversion of nil into String
/home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/railties-5.1.4/lib/rails/test_unit/reporter.rb:70:in
method': undefined method
test_should_be_valid' for classMinitest::Result' (NameError) from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/railties-5.1.4/lib/rails/test_unit/reporter.rb:70:in
format_rerun_snippet' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/railties-5.1.4/lib/rails/test_unit/reporter.rb:23:inrecord' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/minitest-5.11.3/lib/minitest.rb:803:in
block in record' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/minitest-5.11.3/lib/minitest.rb:802:ineach' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/minitest-5.11.3/lib/minitest.rb:802:in
record' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/minitest-5.11.3/lib/minitest.rb:334:inrun_one_method' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/minitest-5.11.3/lib/minitest.rb:321:in
block (2 levels) in run' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/minitest-5.11.3/lib/minitest.rb:320:ineach' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/minitest-5.11.3/lib/minitest.rb:320:in
block in run' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/minitest-5.11.3/lib/minitest.rb:360:inon_signal' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/minitest-5.11.3/lib/minitest.rb:347:in
with_info_handler' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/minitest-5.11.3/lib/minitest.rb:319:inrun' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/railties-5.1.4/lib/rails/test_unit/line_filtering.rb:9:in
run' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/minitest-5.11.3/lib/minitest.rb:159:inblock in __run' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/minitest-5.11.3/lib/minitest.rb:159:in
map' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/minitest-5.11.3/lib/minitest.rb:159:in__run' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/minitest-5.11.3/lib/minitest.rb:136:in
run' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/minitest-5.11.3/lib/minitest.rb:63:inblock in autorun' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/spring-2.0.2/lib/spring/application.rb:171:in
fork' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/spring-2.0.2/lib/spring/application.rb:171:inserve' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/spring-2.0.2/lib/spring/application.rb:141:in
block in run' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/spring-2.0.2/lib/spring/application.rb:135:inloop' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/spring-2.0.2/lib/spring/application.rb:135:in
run' from /home/blake/.rvm/gems/ruby-2.4.1@land_app/gems/spring-2.0.2/lib/spring/application/boot.rb:19:in' from /home/blake/.rvm/rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/rubygems/core_ext/kernel_require.rb:55:in
require' from /home/blake/.rvm/rubies/ruby-2.4.1/lib/ruby/site_ruby/2.4.0/rubygems/core_ext/kernel_require.rb:55:inrequire' from -e:1:in
'
This is from a fairly standard User model test that has not raised issues before...
user.rb
...ANSWER
Answered 2018-Feb-12 at 20:13Got this sorted out by reverting to an earlier commit when things were working as expected, and pulled in needed updates through a $ git checkout
approach.
If I had to guess I think the problem I was having may have had something to do with my intervening update to 2.5.0 through RVM, which introduced more headaches than it was worth (not Rails's fault, or even RVM's since 2.5.0 isn't yet officially supported by RVM).
QUESTION
I want to update my dependencies, it works if I specify the kaminari version to be 0.17.0
But now with this version of kaminari i can't make rails_admin work anymore, see here the error I got => https://github.com/sferik/rails_admin/issues/2939
When I don't specify a version of kaminari i get this error =>
...ANSWER
Answered 2017-Oct-04 at 11:39I solved this issue by also upgrading mongoid dependecies.
Apparently, Kaminari 1.0.1 is not compatible with mongoid-audit 1.0.2
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install fog-openstack
If you're using Keystone V2, you don't need to supply domain details but ensure to either provide a tenant name (openstack_tenant) or a tenant id (openstack_tenant_id). Alternatively you can use :openstack_identity_api_version parameter with 'v2.0'. If you're not sure whether your OpenStack cloud uses Keystone V2 or V3 then you can find out by logging into the dashboard (Horizon) and navigating to "Access & Security" under the "Project" section. Select "API Access" and find the line for the Identity Service. If the endpoint has "v3" in it, you're on Keystone V3, if it has "v2" then (surprise) you're on Keystone V2. If you need a version of OpenStack to test against, get youself a copy of DevStack.
Before you can do anything with an OpenStack cloud, you need to authenticate yourself with the identity service, "Keystone".
All following examples assume that @connection_params is a hash of valid connection information for an OpenStack cloud.
The :openstack_username and :openstack_api_key keys must map to a valid user/password combination in Keystone.
If you don't know what domain your user belongs to, chances are it's the default domain. By default, all users are a member of the default domain unless otherwise specified.
Keystone endpoints are version less. Version 3 is the default as v2.0 is deprecated. Meanwhile Keystone V3 still supports v2.0 for backward compatibility. Therefore passing a tenant instead of a project (along with a domain) makes Keystone provide v2.0 token. Connection parameters:
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page