amazon-pricing 0.1.120 → 0.1.121

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,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- MTIxZTMyYjlmOTZkYzkyM2Q0NzgxOWQ3NDYyYTg0ODE5YWVhZGE1ZA==
4
+ YzUyM2VjNDk5NzU3NTY0MzNkNjdlYTUxOTlkZjcxNWYyMzBkYWQ3OQ==
5
5
  data.tar.gz: !binary |-
6
- MTgyZmU3NjY2NjYxZjI4YmE3MzJmZThiNGM4ZjJiMTkwNjE0NjM5Yw==
6
+ ZmYwN2EwYzFmZjdkNDBlYTdkODMxN2Q5OWRlMWU1N2ZjMGEzYmUzNQ==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- MjJjOWNhYjIwYThhNGJhZGM1ZjBhZDQ5MmZhNzcxMzA2NDMxY2RlMTcxNDJj
10
- ODM4YjgyMGFkZDRiNDJjM2Q2NjAxOTYyYjI5NGQyZGY0YmEyZmQ1NTI2MTEz
11
- MzVhMThmNWE3NjU5YzlkOWJiZTE2MTUzZmFjYmNmNmVlYWZmNjg=
9
+ YjgyNDZlZWM5Yzc2MjkxMjU2NDZmYjU1M2U4ZTkwMjQ0MDI0NzkwN2IzYWNm
10
+ ZTJhODM3OGUzNTQzYTMwYzBjNThjMzNlOGIyNzA3ZTA5Y2U4NmNjYWIzNWZj
11
+ NGQ2NTk5NGYxZDQ2OGZkOGY2OWUwMWQyMzViZTg4YmFiMmM0OTk=
12
12
  data.tar.gz: !binary |-
13
- ZmY0NWIxNDAxYTJkYWY5ZGM5MjEwMjAwMjVmNDU1ZWI4ZDMxNjFlNTMyYmUx
14
- ZTU0YTNmNjg3NjJmY2NjMjJlMDg2NTU3YmRmMmMzMmY0YTQxMDdhYTI0ZWM1
15
- Y2FmY2U0ZjJmZDgxZjk2YmE1MGI2YjRjMmE0NDMwOTMxYmNiNWE=
13
+ MTljZjQ4OTUwZTRhZWI4ZTVmOGMyMGZhM2RlMTljYmY0NjViOTAxYzhjYWM2
14
+ NzM5ZmQxNjExYzY5MjRiOTcxNTAwNWVjMTAxZDZkY2ZjNWQyMGI3ZGZiNWRj
15
+ NjQ4NmNmNDM5M2Q0ZDQ3ZmRjNGQ0YjhjZGIzYjVhOWJlY2U5NGU=
@@ -143,6 +143,35 @@ module AwsPricing
143
143
  network_mbps
144
144
  end
145
145
 
146
+ # Take in string from amazon pricing api, return network properties
147
+ # Input: String containing network capacity from amazon-pricing-api
148
+ # Output: network throughput as a string, int containing network mbps
149
+ def self.get_network_information(network_string)
150
+ throughput = nil
151
+ case network_string
152
+ when 'Very Low'
153
+ throughput = :very_low
154
+ when 'Low'
155
+ throughput = :low
156
+ when 'Low to Moderate'
157
+ throughput = :low_to_moderate
158
+ when 'Moderate'
159
+ throughput = :moderate
160
+ when 'High'
161
+ throughput = :high
162
+ when '10 Gigabit','Up to 10 Gigabit'
163
+ throughput = :ten_gigabit
164
+ when '20 Gigabit'
165
+ throughput = :twenty_gigabit
166
+ when '25 Gigabit'
167
+ throughput = :twentyfive_gigabit
168
+ else
169
+ $stderr.puts "[#{__method__}] WARNING: unknown network throughput string:#{network_string}"
170
+ end
171
+ network_mbps = @Network_Throughput_MBits_Per_Second[throughput]
172
+ [throughput.to_s, network_mbps]
173
+ end
174
+
146
175
  protected
147
176
  # Returns [api_name, name]
148
177
  def self.get_name(instance_type, api_name, is_reserved = false)
@@ -13,6 +13,7 @@ module AwsPricing
13
13
  end
14
14
 
15
15
  protected
16
+
16
17
  @@OS_TYPES = [ 'linux', 'rhel', 'sles', 'mswin',
17
18
  'mswinSQL', 'mswinSQLWeb', 'mswinSQLEnterprise',
18
19
  'linuxSQL', 'linuxSQLWeb', 'linuxSQLEnterprise',
@@ -8,5 +8,5 @@
8
8
  # Home:: http://github.com/CloudHealth/amazon-pricing
9
9
  #++
10
10
  module AwsPricing
11
- VERSION = '0.1.120' # [major,minor.fix]: adding osaka region
12
- end
11
+ VERSION = '0.1.121' # [major,minor.fix]: adding support to allow instance profile population
12
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: amazon-pricing
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.120
4
+ version: 0.1.121
5
5
  platform: ruby
6
6
  authors:
7
7
  - Joe Kinsella
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-10-16 00:00:00.000000000 Z
11
+ date: 2018-10-26 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: A Ruby library for retrieving pricing for Amazon Web Services
14
14
  email: