occi-cli 4.3.9 → 4.3.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: d514c601aafd16b93f02d405c5a6040fd1d6cc65
4
- data.tar.gz: 5d5ed74ecc16de22e0162183cade0f6880313001
3
+ metadata.gz: 1dc9e04fbc0cf3293ecc5e3ae56059ee6e67ce15
4
+ data.tar.gz: 25ed180e7eb9d0d45a1a94a1d6c2b18377f35178
5
5
  SHA512:
6
- metadata.gz: 740921fa7ba5e6b0bb0dc93ddba8f890a7a94766128295655247da436e7986c83d8c1f092318de2e5f44f8966468601e899c79af3619c79c675ef606aedcc771
7
- data.tar.gz: dae114bc9c927dc6bb91d30f1a404aa0e61f2e2eeac4e47db85e2498be9bdb063727686bc097d1ac308614876af41ba83ef12a498cc29cef44b4b00b02690bbd
6
+ metadata.gz: 7e6caa69e122d0c2523162fa8fa2810958c94f0aa8672941e90253c316c614b0fffacf9f74b4165f5350e3635a64e45ae1a337e75c7e7935a4928fc98d51edcf
7
+ data.tar.gz: 5cea0e261d4276af9ad2a401b31bef4a7f0f70afb480fb5c818ecf5df85c725fb7f7e1a3fb3ddeb296d7b31421fed060cf1e5336b6eca561e436ac6eac5a66c3
data/bin/occi CHANGED
@@ -21,7 +21,7 @@ require 'highline/import'
21
21
 
22
22
  require 'occi-cli'
23
23
 
24
- NONPASS_AUTHS = %w(none token).freeze
24
+ NONPASS_AUTHS = %w(none token oauth2).freeze
25
25
 
26
26
  # get arguments and validate/parse them to an ostruct
27
27
  options = Occi::Cli::OcciOpts.parse ARGV
@@ -82,6 +82,11 @@ module Occi::Cli::Helpers::CreateHelper
82
82
  elsif link.include? "/network/"
83
83
  Occi::Cli::Log.debug "Adding networkinterface to #{options.resource.inspect}"
84
84
  res.networkinterface link
85
+ elsif link.include? "/securitygroup/"
86
+ Occi::Cli::Log.debug "Adding securitygrouplink to #{options.resource.inspect}"
87
+ kind = 'http://schemas.ogf.org/occi/infrastructure#securitygrouplink'
88
+ sec_grp_kind = 'http://schemas.ogf.org/occi/infrastructure#securitygroup'
89
+ res.link link, kind, [], Occi::Core::Attributes.new, sec_grp_kind
85
90
  else
86
91
  raise "Unknown link type #{link.inspect}, stopping here!"
87
92
  end
@@ -28,12 +28,15 @@ module Occi::Cli::Helpers::LinkHelper
28
28
  raise "No valid links given!" if link.blank?
29
29
 
30
30
  case link
31
- when /\/network\//
31
+ when /\/network\//, /\/ipreservation\//
32
32
  link_kind = model.get_by_id("http://schemas.ogf.org/occi/infrastructure#networkinterface")
33
33
  raise "#{options.endpoint.inspect} does not support networkinterface links!" unless link_kind
34
34
  when /\/storage\//
35
35
  link_kind = model.get_by_id("http://schemas.ogf.org/occi/infrastructure#storagelink")
36
36
  raise "#{options.endpoint.inspect} does not support storagelink links!" unless link_kind
37
+ when /\/securitygroup\//
38
+ link_kind = model.get_by_id("http://schemas.ogf.org/occi/infrastructure#securitygrouplink")
39
+ raise "#{options.endpoint.inspect} does not support securitygroup links!" unless link_kind
37
40
  else
38
41
  raise "Unknown link target #{link.inspect}! Only network and storage targets are supported!"
39
42
  end
@@ -76,4 +79,4 @@ module Occi::Cli::Helpers::LinkHelper
76
79
  end
77
80
  end
78
81
 
79
- end
82
+ end
@@ -9,7 +9,7 @@ module Occi::Cli
9
9
 
10
10
  class OcciOpts
11
11
 
12
- AUTH_METHODS = [:x509, :token, :basic, :digest, :none].freeze
12
+ AUTH_METHODS = [:x509, :token, :basic, :digest, :oauth2, :none].freeze
13
13
  MEDIA_TYPES = ["application/occi+json", "text/plain,text/occi", "text/plain", "text/occi"].freeze
14
14
  ACTIONS = [:list, :describe, :create, :delete, :trigger, :link, :unlink, :discover, :update].freeze
15
15
  LOG_OUTPUTS = [:stdout, :stderr].freeze
@@ -1,5 +1,5 @@
1
1
  module Occi
2
2
  module Cli
3
- VERSION = "4.3.9" unless defined?(::Occi::Cli::VERSION)
3
+ VERSION = "4.3.10" unless defined?(::Occi::Cli::VERSION)
4
4
  end
5
5
  end
@@ -19,7 +19,7 @@ Gem::Specification.new do |gem|
19
19
  gem.test_files = `git ls-files -- {test,spec}/*`.split("\n")
20
20
  gem.require_paths = ['lib']
21
21
 
22
- gem.add_dependency 'occi-api', '>= 4.3.11', '< 5'
22
+ gem.add_dependency 'occi-api', '>= 4.3.14', '< 5'
23
23
  gem.add_dependency 'json', '>= 1.8.1', '< 3'
24
24
  gem.add_dependency 'highline', '>= 1.6.21', '< 2'
25
25
  gem.add_dependency 'activesupport', '>= 4.0.0', '< 5'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: occi-cli
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.3.9
4
+ version: 4.3.10
5
5
  platform: ruby
6
6
  authors:
7
7
  - Florian Feldhaus
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2017-02-14 00:00:00.000000000 Z
13
+ date: 2017-08-15 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: occi-api
@@ -18,7 +18,7 @@ dependencies:
18
18
  requirements:
19
19
  - - ">="
20
20
  - !ruby/object:Gem::Version
21
- version: 4.3.11
21
+ version: 4.3.14
22
22
  - - "<"
23
23
  - !ruby/object:Gem::Version
24
24
  version: '5'
@@ -28,7 +28,7 @@ dependencies:
28
28
  requirements:
29
29
  - - ">="
30
30
  - !ruby/object:Gem::Version
31
- version: 4.3.11
31
+ version: 4.3.14
32
32
  - - "<"
33
33
  - !ruby/object:Gem::Version
34
34
  version: '5'
@@ -326,7 +326,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
326
326
  version: '0'
327
327
  requirements: []
328
328
  rubyforge_project:
329
- rubygems_version: 2.4.8
329
+ rubygems_version: 2.6.12
330
330
  signing_key:
331
331
  specification_version: 4
332
332
  summary: Executable OCCI client