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
################################################ | |
# GET (describe) will fail for recently created | |
# resources. | |
# | |
# to reproduce, run examples/x509auth_example.rb | |
################################################ | |
D, [2012-11-07T20:02:07.836934 #18365] DEBUG -- : Parsed collection: empty? true | |
[~/.rvm/gems/ruby-1.9.3-p194/gems/occi-3.0.0.alpha.0/lib/occi/collection.rb:134:in `as_json': undefined method `size' for nil:NilClass (NoMethodError) | |
from ~/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.8/lib/active_support/json/encoding.rb:47:in `block in encode' |
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
VCR.configure do |c| | |
c.hook_into :webmock | |
c.cassette_library_dir = 'spec/cassettes' | |
c.default_cassette_options = { :record => :new_episodes } | |
## Ignore some requests based on the hosts involved. | |
c.ignore_hosts 'localhost', '8.8.8.8', 'our.local.test.server.org' | |
## Ignore some requests based on their properties. | |
# The block passed to c.ignore_request has to |
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
POST /compute/ HTTP/1.1 | |
Accept: text/uri-list | |
Content-Type: application/occi+json | |
Connection: close | |
Host: localhost | |
Content-Length: 599 | |
{"resources":[{"kind":"http://schemas.ogf.org/occi/infrastructure#compute","mixins":["https://occi.localhost/occi/infrastructure/resource_tpl#medium"]}],"links":[{"kind":"http://schemas.ogf.org/occi/infrastructure#storagelink","rel":"http://schemas.ogf.org/occi/infrastructure#storage","target":"https://localhost/storage/e60aa2b8-0c86-5973-b93e-30c5c46d6eac"},{"kind":"http://schemas.ogf.org/occi/infrastructure#networkinterface","rel":"http://schemas.ogf.org/occi/core#resource","target":"https://localhost/network/d71df087-9a55-5228-822b-1f1a57107851"}]} | |
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
D, [2013-01-03T12:19:26.894193 #6645] DEBUG -- : ### Client Accept: ["text/uri-list"] | |
D, [2013-01-03T12:19:26.894599 #6645] DEBUG -- : ### Client Request method: POST | |
D, [2013-01-03T12:19:26.894722 #6645] DEBUG -- : ### Client Request Media Type: application/occi+json | |
D, [2013-01-03T12:19:26.894989 #6645] DEBUG -- : ### Client Request header: {"HTTPS"=>"on", "HTTP_ACCEPT"=>"text/uri-list", "HTTP_CONNECTION"=>"close", "HTTP_HOST"=>"localhost"} | |
D, [2013-01-03T12:19:26.895720 #6645] DEBUG -- : ### Client Request body: {"resources":[{"kind":"http://schemas.ogf.org/occi/infrastructure#compute","mixins":["https://occi.localhost/occi/infrastructure/resource_tpl#medium"]}],"links":[{"kind":"http://schemas.ogf.org/occi/infrastructure#storagelink","rel":"http://schemas.ogf.org/occi/infrastructure#storage","target":"https://localhost/storage/e60aa2b8-0c86-5973-b93e-30c5c46d6eac"},{"kind":"http://schemas.ogf.org/occi/infrastructure#networkinterface","rel":"http://schemas.ogf.org/occi/core#resource","target":"https://loca |
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
OpenSSL::SSL::SSLError: Received fatal alert: decrypt_error | |
connect at org/jruby/ext/openssl/SSLSocket.java:170 | |
connect at jar:file:/tmp/jruby7520675521007850409extract/jruby-stdlib-1.7.2.jar!/META-INF/jruby.home/lib/ruby/1.9/net/http.rb:799 | |
timeout at org/jruby/ext/timeout/Timeout.java:105 | |
connect at jar:file:/tmp/jruby7520675521007850409extract/jruby-stdlib-1.7.2.jar!/META-INF/jruby.home/lib/ruby/1.9/net/http.rb:799 | |
do_start at jar:file:/tmp/jruby7520675521007850409extract/jruby-stdlib-1.7.2.jar!/META-INF/jruby.home/lib/ruby/1.9/net/http.rb:755 | |
start at jar:file:/tmp/jruby7520675521007850409extract/jruby-stdlib-1.7.2.jar!/META-INF/jruby.home/lib/ruby/1.9/net/http.rb:744 | |
request at jar:file:/tmp/jruby7520675521007850409extract/jruby-stdlib-1.7.2.jar!/META-INF/jruby.home/lib/ruby/1.9/net/http.rb:1292 | |
perform at /home/arax/.rvm/gems/jruby-1.7.2/gems/httparty-0.10.2/lib/httparty/request.rb:91 | |
perform_request at /home/arax/.rvm/ge |
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
# Gets the username associated with a password | |
# password:: _String_ the password | |
# [return] _Hash_ with the username | |
def get_username(password) | |
xpath = "USER[PASSWORD=\"#{password}\"]/NAME" | |
username = retrieve_from_userpool(xpath) | |
# No exact match, trying to match password with each | |
# of the pipe-separated DNs stored in USER/PASSWORD | |
if username.nil? |
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 'java' | |
require 'highline/import' | |
keystore = Java::JavaSecurity::KeyStore.getInstance("PKCS12") | |
path = ask "Enter full path to the PKCS#12 file: " | |
fis = Java::JavaIo::FileInputStream.new(path) | |
password = ask("Enter you PKCS#12 password: ") { |q| q.echo = false } | |
password = Java::JavaLang::String.new(password).to_char_array |
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
Category: compute;scheme="http://schemas.ogf.org/occi/infrastructure#";class="kind" | |
Category: small;scheme="https://occi.my.scheme/occi/infrastructure/resource_tpl#";class="mixin" | |
X-OCCI-Attribute: occi.core.title="My Test VM" | |
Link: </storage/e60aa2b8-0c86-5973-b93e-30c5c46d6eac>;rel="http://schemas.ogf.org/occi/infrastructure#storage";category="http://schemas.ogf.org/occi/infrastructure#storagelink";occi.core.target="/storage/e60aa2b8-0c86-5973-b93e-30c5c46d6eac" | |
Link: </network/e4bd81c4-adda-5626-840d-39bb7959db97>;rel="http://schemas.ogf.org/occi/core#resource";category="http://schemas.ogf.org/occi/infrastructure#networkinterface";occi.core.target="/network/e4bd81c4-adda-5626-840d-39bb7959db97" | |
D, [2013-02-22T13:20:35.249918 #31553] DEBUG -- : ### Prepare response ### | |
D, [2013-02-22T13:20:35.250061 #31553] DEBUG -- : ### Initialize response OCCI collection ### | |
D, [2013-02-22T13:20:35.250307 #31553] DEBUG -- : ### Reset OCCI model ### |
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 'httpi' | |
require 'curb' | |
require 'pp' | |
require 'json' | |
################################ | |
# kinit user@REALM | |
# kinit -k -t /ticket/path | |
################################ |
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
~/.rvm/gems/ruby-1.9.3-p392/gems/occi-3.2.0.alpha.1/lib/occi/parser/text.rb:134:in `category': could not match Category: egicf2012_demo;scheme="https://occi.schema/occi/infrastructure/os_tpl#";class="mixin";title="egicf2012-demo";rel="http://schemas.ogf.org/occi/infrastructure#os_tpl";location="/mixins/egicf2012_demo/" (RuntimeError) | |
from /home/arax/.rvm/gems/ruby-1.9.3-p392/gems/occi-3.2.0.alpha.1/lib/occi/parser/text.rb:73:in `block in categories' | |
from /home/arax/.rvm/gems/ruby-1.9.3-p392/gems/occi-3.2.0.alpha.1/lib/occi/parser/text.rb:71:in `each' | |
from /home/arax/.rvm/gems/ruby-1.9.3-p392/gems/occi-3.2.0.alpha.1/lib/occi/parser/text.rb:71:in `categories' | |
from /home/arax/.rvm/gems/ruby-1.9.3-p392/gems/occi-3.2.0.alpha.1/lib/occi/parser.rb:41:in `parse' |