pnap_rancher_api 1.0.0

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.
Files changed (48) hide show
  1. checksums.yaml +7 -0
  2. data/Gemfile +9 -0
  3. data/README.md +154 -0
  4. data/Rakefile +10 -0
  5. data/VERSION +1 -0
  6. data/docs/Cluster.md +36 -0
  7. data/docs/ClustersApi.md +286 -0
  8. data/docs/DeleteResult.md +20 -0
  9. data/docs/Error.md +20 -0
  10. data/docs/Node.md +18 -0
  11. data/docs/NodePool.md +26 -0
  12. data/docs/RancherClusterCertificates.md +22 -0
  13. data/docs/RancherClusterConfig.md +30 -0
  14. data/docs/RancherServerMetadata.md +22 -0
  15. data/docs/SshConfig.md +22 -0
  16. data/docs/WorkloadClusterConfig.md +24 -0
  17. data/lib/pnap_rancher_api/api/clusters_api.rb +269 -0
  18. data/lib/pnap_rancher_api/api_client.rb +392 -0
  19. data/lib/pnap_rancher_api/api_error.rb +57 -0
  20. data/lib/pnap_rancher_api/configuration.rb +278 -0
  21. data/lib/pnap_rancher_api/models/cluster.rb +341 -0
  22. data/lib/pnap_rancher_api/models/delete_result.rb +235 -0
  23. data/lib/pnap_rancher_api/models/error.rb +236 -0
  24. data/lib/pnap_rancher_api/models/node.rb +220 -0
  25. data/lib/pnap_rancher_api/models/node_pool.rb +264 -0
  26. data/lib/pnap_rancher_api/models/rancher_cluster_certificates.rb +240 -0
  27. data/lib/pnap_rancher_api/models/rancher_cluster_config.rb +284 -0
  28. data/lib/pnap_rancher_api/models/rancher_server_metadata.rb +240 -0
  29. data/lib/pnap_rancher_api/models/ssh_config.rb +246 -0
  30. data/lib/pnap_rancher_api/models/workload_cluster_config.rb +264 -0
  31. data/lib/pnap_rancher_api/version.rb +19 -0
  32. data/lib/pnap_rancher_api.rb +50 -0
  33. data/pnap_rancher_api.gemspec +39 -0
  34. data/spec/api/clusters_api_spec.rb +82 -0
  35. data/spec/api_client_spec.rb +226 -0
  36. data/spec/configuration_spec.rb +42 -0
  37. data/spec/models/cluster_spec.rb +88 -0
  38. data/spec/models/delete_result_spec.rb +40 -0
  39. data/spec/models/error_spec.rb +40 -0
  40. data/spec/models/node_pool_spec.rb +58 -0
  41. data/spec/models/node_spec.rb +34 -0
  42. data/spec/models/rancher_cluster_certificates_spec.rb +46 -0
  43. data/spec/models/rancher_cluster_config_spec.rb +70 -0
  44. data/spec/models/rancher_server_metadata_spec.rb +46 -0
  45. data/spec/models/ssh_config_spec.rb +46 -0
  46. data/spec/models/workload_cluster_config_spec.rb +52 -0
  47. data/spec/spec_helper.rb +111 -0
  48. metadata +144 -0
@@ -0,0 +1,246 @@
1
+ =begin
2
+ #Rancher Solution API
3
+
4
+ #Simplify enterprise-grade Kubernetes cluster operations and management with Rancher on Bare Metal Cloud. Deploy Kubernetes clusters using a few API calls.<br> <br> <span class='pnap-api-knowledge-base-link'> Knowledge base articles to help you can be found <a href='https://phoenixnap.com/kb/rancher-bmc-integration-kubernetes' target='_blank'>here</a> </span><br> <br> <b>All URLs are relative to (https://api.phoenixnap.com/solutions/rancher/v1beta)</b>
5
+
6
+ The version of the OpenAPI document: 0.1
7
+ Contact: support@phoenixnap.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.4.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module RancherApi
17
+ # (Write-only) Configuration defining which public SSH keys are pre-installed as authorized on the server.
18
+ class SshConfig
19
+ # Define whether public keys marked as default should be installed on this node. These are public keys that were already recorded on this system. Use <a href='https://developers.phoenixnap.com/docs/bmc/1/routes/ssh-keys/get' target='_blank'>GET /ssh-keys</a> to retrieve a list of possible values.
20
+ attr_accessor :install_default_keys
21
+
22
+ # List of public SSH keys.
23
+ attr_accessor :keys
24
+
25
+ # List of public SSH key identifiers. These are public keys that were already recorded on this system. Use <a href='https://developers.phoenixnap.com/docs/bmc/1/routes/ssh-keys/get' target='_blank'>GET /ssh-keys</a> to retrieve a list of possible values.
26
+ attr_accessor :key_ids
27
+
28
+ # Attribute mapping from ruby-style variable name to JSON key.
29
+ def self.attribute_map
30
+ {
31
+ :'install_default_keys' => :'installDefaultKeys',
32
+ :'keys' => :'keys',
33
+ :'key_ids' => :'keyIds'
34
+ }
35
+ end
36
+
37
+ # Returns all the JSON keys this model knows about
38
+ def self.acceptable_attributes
39
+ attribute_map.values
40
+ end
41
+
42
+ # Attribute type mapping.
43
+ def self.openapi_types
44
+ {
45
+ :'install_default_keys' => :'Boolean',
46
+ :'keys' => :'Array<String>',
47
+ :'key_ids' => :'Array<String>'
48
+ }
49
+ end
50
+
51
+ # List of attributes with nullable: true
52
+ def self.openapi_nullable
53
+ Set.new([
54
+ ])
55
+ end
56
+
57
+ # Initializes the object
58
+ # @param [Hash] attributes Model attributes in the form of hash
59
+ def initialize(attributes = {})
60
+ if (!attributes.is_a?(Hash))
61
+ fail ArgumentError, "The input argument (attributes) must be a hash in `RancherApi::SshConfig` initialize method"
62
+ end
63
+
64
+ # check to see if the attribute exists and convert string to symbol for hash key
65
+ attributes = attributes.each_with_object({}) { |(k, v), h|
66
+ if (!self.class.attribute_map.key?(k.to_sym))
67
+ fail ArgumentError, "`#{k}` is not a valid attribute in `RancherApi::SshConfig`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
68
+ end
69
+ h[k.to_sym] = v
70
+ }
71
+
72
+ if attributes.key?(:'install_default_keys')
73
+ self.install_default_keys = attributes[:'install_default_keys']
74
+ else
75
+ self.install_default_keys = true
76
+ end
77
+
78
+ if attributes.key?(:'keys')
79
+ if (value = attributes[:'keys']).is_a?(Array)
80
+ self.keys = value
81
+ end
82
+ end
83
+
84
+ if attributes.key?(:'key_ids')
85
+ if (value = attributes[:'key_ids']).is_a?(Array)
86
+ self.key_ids = value
87
+ end
88
+ end
89
+ end
90
+
91
+ # Show invalid properties with the reasons. Usually used together with valid?
92
+ # @return Array for valid properties with the reasons
93
+ def list_invalid_properties
94
+ invalid_properties = Array.new
95
+ invalid_properties
96
+ end
97
+
98
+ # Check to see if the all the properties in the model are valid
99
+ # @return true if the model is valid
100
+ def valid?
101
+ true
102
+ end
103
+
104
+ # Checks equality by comparing each attribute.
105
+ # @param [Object] Object to be compared
106
+ def ==(o)
107
+ return true if self.equal?(o)
108
+ self.class == o.class &&
109
+ install_default_keys == o.install_default_keys &&
110
+ keys == o.keys &&
111
+ key_ids == o.key_ids
112
+ end
113
+
114
+ # @see the `==` method
115
+ # @param [Object] Object to be compared
116
+ def eql?(o)
117
+ self == o
118
+ end
119
+
120
+ # Calculates hash code according to all attributes.
121
+ # @return [Integer] Hash code
122
+ def hash
123
+ [install_default_keys, keys, key_ids].hash
124
+ end
125
+
126
+ # Builds the object from hash
127
+ # @param [Hash] attributes Model attributes in the form of hash
128
+ # @return [Object] Returns the model itself
129
+ def self.build_from_hash(attributes)
130
+ new.build_from_hash(attributes)
131
+ end
132
+
133
+ # Builds the object from hash
134
+ # @param [Hash] attributes Model attributes in the form of hash
135
+ # @return [Object] Returns the model itself
136
+ def build_from_hash(attributes)
137
+ return nil unless attributes.is_a?(Hash)
138
+ self.class.openapi_types.each_pair do |key, type|
139
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
140
+ self.send("#{key}=", nil)
141
+ elsif type =~ /\AArray<(.*)>/i
142
+ # check to ensure the input is an array given that the attribute
143
+ # is documented as an array but the input is not
144
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
145
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
146
+ end
147
+ elsif !attributes[self.class.attribute_map[key]].nil?
148
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
149
+ end
150
+ end
151
+
152
+ self
153
+ end
154
+
155
+ # Deserializes the data based on type
156
+ # @param string type Data type
157
+ # @param string value Value to be deserialized
158
+ # @return [Object] Deserialized data
159
+ def _deserialize(type, value)
160
+ case type.to_sym
161
+ when :Time
162
+ Time.parse(value)
163
+ when :Date
164
+ Date.parse(value)
165
+ when :String
166
+ value.to_s
167
+ when :Integer
168
+ value.to_i
169
+ when :Float
170
+ value.to_f
171
+ when :Boolean
172
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
173
+ true
174
+ else
175
+ false
176
+ end
177
+ when :Object
178
+ # generic object (usually a Hash), return directly
179
+ value
180
+ when /\AArray<(?<inner_type>.+)>\z/
181
+ inner_type = Regexp.last_match[:inner_type]
182
+ value.map { |v| _deserialize(inner_type, v) }
183
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
184
+ k_type = Regexp.last_match[:k_type]
185
+ v_type = Regexp.last_match[:v_type]
186
+ {}.tap do |hash|
187
+ value.each do |k, v|
188
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
189
+ end
190
+ end
191
+ else # model
192
+ # models (e.g. Pet) or oneOf
193
+ klass = RancherApi.const_get(type)
194
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
195
+ end
196
+ end
197
+
198
+ # Returns the string representation of the object
199
+ # @return [String] String presentation of the object
200
+ def to_s
201
+ to_hash.to_s
202
+ end
203
+
204
+ # to_body is an alias to to_hash (backward compatibility)
205
+ # @return [Hash] Returns the object in the form of hash
206
+ def to_body
207
+ to_hash
208
+ end
209
+
210
+ # Returns the object in the form of hash
211
+ # @return [Hash] Returns the object in the form of hash
212
+ def to_hash
213
+ hash = {}
214
+ self.class.attribute_map.each_pair do |attr, param|
215
+ value = self.send(attr)
216
+ if value.nil?
217
+ is_nullable = self.class.openapi_nullable.include?(attr)
218
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
219
+ end
220
+
221
+ hash[param] = _to_hash(value)
222
+ end
223
+ hash
224
+ end
225
+
226
+ # Outputs non-array value in the form of hash
227
+ # For object, use to_hash. Otherwise, just return the value
228
+ # @param [Object] value Any valid value
229
+ # @return [Hash] Returns the value in the form of hash
230
+ def _to_hash(value)
231
+ if value.is_a?(Array)
232
+ value.compact.map { |v| _to_hash(v) }
233
+ elsif value.is_a?(Hash)
234
+ {}.tap do |hash|
235
+ value.each { |k, v| hash[k] = _to_hash(v) }
236
+ end
237
+ elsif value.respond_to? :to_hash
238
+ value.to_hash
239
+ else
240
+ value
241
+ end
242
+ end
243
+
244
+ end
245
+
246
+ end
@@ -0,0 +1,264 @@
1
+ =begin
2
+ #Rancher Solution API
3
+
4
+ #Simplify enterprise-grade Kubernetes cluster operations and management with Rancher on Bare Metal Cloud. Deploy Kubernetes clusters using a few API calls.<br> <br> <span class='pnap-api-knowledge-base-link'> Knowledge base articles to help you can be found <a href='https://phoenixnap.com/kb/rancher-bmc-integration-kubernetes' target='_blank'>here</a> </span><br> <br> <b>All URLs are relative to (https://api.phoenixnap.com/solutions/rancher/v1beta)</b>
5
+
6
+ The version of the OpenAPI document: 0.1
7
+ Contact: support@phoenixnap.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.4.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module RancherApi
17
+ # (Write-only) Workload cluster configuration parameters.
18
+ class WorkloadClusterConfig
19
+ # The name of the workload cluster. This field is autogenerated if not provided.
20
+ attr_accessor :name
21
+
22
+ # Number of configured servers. Currently only server counts of 1 and 3 are possible.
23
+ attr_accessor :server_count
24
+
25
+ # Node server type. Cannot be changed once the cluster is created. Currently this field should be set to either `s0.d1.small`, `s0.d1.medium`, `s1.c1.small`, `s1.c1.medium`, `s1.c2.medium`, `s1.c2.large`, `s1.e1.small`, `s1.e1.medium`, `s1.e1.large`, `s2.c1.small`, `s2.c1.medium`, `s2.c1.large`, `s2.c2.small`, `s2.c2.medium`, `s2.c2.large`, `d1.c1.small`, `d1.c2.small`, `d1.c3.small`, `d1.c4.small`, `d1.c1.medium`, `d1.c2.medium`, `d1.c3.medium`, `d1.c4.medium`, `d1.c1.large`, `d1.c2.large`, `d1.c3.large`, `d1.c4.large`, `d1.m1.medium`, `d1.m2.medium`, `d1.m3.medium`, `d1.m4.medium`, `d2.c3.medium`, `d2.c4.medium`, `d2.c5.medium`, `d2.c3.large`, `d2.c4.large`, `d2.c5.large`, `d2.m2.medium`, `d2.m2.large` or `d2.m2.xlarge`.
26
+ attr_accessor :server_type
27
+
28
+ # Workload cluster location. Cannot be changed once cluster is created. Currently this field should be set to `PHX`, `ASH`, `SGP`, `NLD`, `CHI`, `SEA` or `AUS`.
29
+ attr_accessor :location
30
+
31
+ # Attribute mapping from ruby-style variable name to JSON key.
32
+ def self.attribute_map
33
+ {
34
+ :'name' => :'name',
35
+ :'server_count' => :'serverCount',
36
+ :'server_type' => :'serverType',
37
+ :'location' => :'location'
38
+ }
39
+ end
40
+
41
+ # Returns all the JSON keys this model knows about
42
+ def self.acceptable_attributes
43
+ attribute_map.values
44
+ end
45
+
46
+ # Attribute type mapping.
47
+ def self.openapi_types
48
+ {
49
+ :'name' => :'String',
50
+ :'server_count' => :'Integer',
51
+ :'server_type' => :'String',
52
+ :'location' => :'String'
53
+ }
54
+ end
55
+
56
+ # List of attributes with nullable: true
57
+ def self.openapi_nullable
58
+ Set.new([
59
+ ])
60
+ end
61
+
62
+ # Initializes the object
63
+ # @param [Hash] attributes Model attributes in the form of hash
64
+ def initialize(attributes = {})
65
+ if (!attributes.is_a?(Hash))
66
+ fail ArgumentError, "The input argument (attributes) must be a hash in `RancherApi::WorkloadClusterConfig` initialize method"
67
+ end
68
+
69
+ # check to see if the attribute exists and convert string to symbol for hash key
70
+ attributes = attributes.each_with_object({}) { |(k, v), h|
71
+ if (!self.class.attribute_map.key?(k.to_sym))
72
+ fail ArgumentError, "`#{k}` is not a valid attribute in `RancherApi::WorkloadClusterConfig`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
73
+ end
74
+ h[k.to_sym] = v
75
+ }
76
+
77
+ if attributes.key?(:'name')
78
+ self.name = attributes[:'name']
79
+ end
80
+
81
+ if attributes.key?(:'server_count')
82
+ self.server_count = attributes[:'server_count']
83
+ else
84
+ self.server_count = 1
85
+ end
86
+
87
+ if attributes.key?(:'server_type')
88
+ self.server_type = attributes[:'server_type']
89
+ else
90
+ self.server_type = 's0.d1.small'
91
+ end
92
+
93
+ if attributes.key?(:'location')
94
+ self.location = attributes[:'location']
95
+ end
96
+ end
97
+
98
+ # Show invalid properties with the reasons. Usually used together with valid?
99
+ # @return Array for valid properties with the reasons
100
+ def list_invalid_properties
101
+ invalid_properties = Array.new
102
+ if @server_type.nil?
103
+ invalid_properties.push('invalid value for "server_type", server_type cannot be nil.')
104
+ end
105
+
106
+ if @location.nil?
107
+ invalid_properties.push('invalid value for "location", location cannot be nil.')
108
+ end
109
+
110
+ invalid_properties
111
+ end
112
+
113
+ # Check to see if the all the properties in the model are valid
114
+ # @return true if the model is valid
115
+ def valid?
116
+ return false if @server_type.nil?
117
+ return false if @location.nil?
118
+ true
119
+ end
120
+
121
+ # Checks equality by comparing each attribute.
122
+ # @param [Object] Object to be compared
123
+ def ==(o)
124
+ return true if self.equal?(o)
125
+ self.class == o.class &&
126
+ name == o.name &&
127
+ server_count == o.server_count &&
128
+ server_type == o.server_type &&
129
+ location == o.location
130
+ end
131
+
132
+ # @see the `==` method
133
+ # @param [Object] Object to be compared
134
+ def eql?(o)
135
+ self == o
136
+ end
137
+
138
+ # Calculates hash code according to all attributes.
139
+ # @return [Integer] Hash code
140
+ def hash
141
+ [name, server_count, server_type, location].hash
142
+ end
143
+
144
+ # Builds the object from hash
145
+ # @param [Hash] attributes Model attributes in the form of hash
146
+ # @return [Object] Returns the model itself
147
+ def self.build_from_hash(attributes)
148
+ new.build_from_hash(attributes)
149
+ end
150
+
151
+ # Builds the object from hash
152
+ # @param [Hash] attributes Model attributes in the form of hash
153
+ # @return [Object] Returns the model itself
154
+ def build_from_hash(attributes)
155
+ return nil unless attributes.is_a?(Hash)
156
+ self.class.openapi_types.each_pair do |key, type|
157
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
158
+ self.send("#{key}=", nil)
159
+ elsif type =~ /\AArray<(.*)>/i
160
+ # check to ensure the input is an array given that the attribute
161
+ # is documented as an array but the input is not
162
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
163
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
164
+ end
165
+ elsif !attributes[self.class.attribute_map[key]].nil?
166
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
167
+ end
168
+ end
169
+
170
+ self
171
+ end
172
+
173
+ # Deserializes the data based on type
174
+ # @param string type Data type
175
+ # @param string value Value to be deserialized
176
+ # @return [Object] Deserialized data
177
+ def _deserialize(type, value)
178
+ case type.to_sym
179
+ when :Time
180
+ Time.parse(value)
181
+ when :Date
182
+ Date.parse(value)
183
+ when :String
184
+ value.to_s
185
+ when :Integer
186
+ value.to_i
187
+ when :Float
188
+ value.to_f
189
+ when :Boolean
190
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
191
+ true
192
+ else
193
+ false
194
+ end
195
+ when :Object
196
+ # generic object (usually a Hash), return directly
197
+ value
198
+ when /\AArray<(?<inner_type>.+)>\z/
199
+ inner_type = Regexp.last_match[:inner_type]
200
+ value.map { |v| _deserialize(inner_type, v) }
201
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
202
+ k_type = Regexp.last_match[:k_type]
203
+ v_type = Regexp.last_match[:v_type]
204
+ {}.tap do |hash|
205
+ value.each do |k, v|
206
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
207
+ end
208
+ end
209
+ else # model
210
+ # models (e.g. Pet) or oneOf
211
+ klass = RancherApi.const_get(type)
212
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
213
+ end
214
+ end
215
+
216
+ # Returns the string representation of the object
217
+ # @return [String] String presentation of the object
218
+ def to_s
219
+ to_hash.to_s
220
+ end
221
+
222
+ # to_body is an alias to to_hash (backward compatibility)
223
+ # @return [Hash] Returns the object in the form of hash
224
+ def to_body
225
+ to_hash
226
+ end
227
+
228
+ # Returns the object in the form of hash
229
+ # @return [Hash] Returns the object in the form of hash
230
+ def to_hash
231
+ hash = {}
232
+ self.class.attribute_map.each_pair do |attr, param|
233
+ value = self.send(attr)
234
+ if value.nil?
235
+ is_nullable = self.class.openapi_nullable.include?(attr)
236
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
237
+ end
238
+
239
+ hash[param] = _to_hash(value)
240
+ end
241
+ hash
242
+ end
243
+
244
+ # Outputs non-array value in the form of hash
245
+ # For object, use to_hash. Otherwise, just return the value
246
+ # @param [Object] value Any valid value
247
+ # @return [Hash] Returns the value in the form of hash
248
+ def _to_hash(value)
249
+ if value.is_a?(Array)
250
+ value.compact.map { |v| _to_hash(v) }
251
+ elsif value.is_a?(Hash)
252
+ {}.tap do |hash|
253
+ value.each { |k, v| hash[k] = _to_hash(v) }
254
+ end
255
+ elsif value.respond_to? :to_hash
256
+ value.to_hash
257
+ else
258
+ value
259
+ end
260
+ end
261
+
262
+ end
263
+
264
+ end
@@ -0,0 +1,19 @@
1
+ =begin
2
+ #Rancher Solution API
3
+
4
+ #Simplify enterprise-grade Kubernetes cluster operations and management with Rancher on Bare Metal Cloud. Deploy Kubernetes clusters using a few API calls.<br> <br> <span class='pnap-api-knowledge-base-link'> Knowledge base articles to help you can be found <a href='https://phoenixnap.com/kb/rancher-bmc-integration-kubernetes' target='_blank'>here</a> </span><br> <br> <b>All URLs are relative to (https://api.phoenixnap.com/solutions/rancher/v1beta)</b>
5
+
6
+ The version of the OpenAPI document: 0.1
7
+ Contact: support@phoenixnap.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.4.0
10
+
11
+ =end
12
+
13
+ def get_version()
14
+ return File.read(File.expand_path('../../../VERSION', __FILE__)).strip
15
+ end
16
+
17
+ module RancherApi
18
+ VERSION = get_version()
19
+ end
@@ -0,0 +1,50 @@
1
+ =begin
2
+ #Rancher Solution API
3
+
4
+ #Simplify enterprise-grade Kubernetes cluster operations and management with Rancher on Bare Metal Cloud. Deploy Kubernetes clusters using a few API calls.<br> <br> <span class='pnap-api-knowledge-base-link'> Knowledge base articles to help you can be found <a href='https://phoenixnap.com/kb/rancher-bmc-integration-kubernetes' target='_blank'>here</a> </span><br> <br> <b>All URLs are relative to (https://api.phoenixnap.com/solutions/rancher/v1beta)</b>
5
+
6
+ The version of the OpenAPI document: 0.1
7
+ Contact: support@phoenixnap.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.4.0
10
+
11
+ =end
12
+
13
+ # Common files
14
+ require 'pnap_rancher_api/api_client'
15
+ require 'pnap_rancher_api/api_error'
16
+ require 'pnap_rancher_api/version'
17
+ require 'pnap_rancher_api/configuration'
18
+
19
+ # Models
20
+ require 'pnap_rancher_api/models/cluster'
21
+ require 'pnap_rancher_api/models/delete_result'
22
+ require 'pnap_rancher_api/models/error'
23
+ require 'pnap_rancher_api/models/node'
24
+ require 'pnap_rancher_api/models/node_pool'
25
+ require 'pnap_rancher_api/models/rancher_cluster_certificates'
26
+ require 'pnap_rancher_api/models/rancher_cluster_config'
27
+ require 'pnap_rancher_api/models/rancher_server_metadata'
28
+ require 'pnap_rancher_api/models/ssh_config'
29
+ require 'pnap_rancher_api/models/workload_cluster_config'
30
+
31
+ # APIs
32
+ require 'pnap_rancher_api/api/clusters_api'
33
+
34
+ module RancherApi
35
+ class << self
36
+ # Customize default settings for the SDK using block.
37
+ # RancherApi.configure do |config|
38
+ # config.username = "xxx"
39
+ # config.password = "xxx"
40
+ # end
41
+ # If no block given, return the default Configuration object.
42
+ def configure
43
+ if block_given?
44
+ yield(Configuration.default)
45
+ else
46
+ Configuration.default
47
+ end
48
+ end
49
+ end
50
+ end
@@ -0,0 +1,39 @@
1
+ # -*- encoding: utf-8 -*-
2
+
3
+ =begin
4
+ #Rancher Solution API
5
+
6
+ #Simplify enterprise-grade Kubernetes cluster operations and management with Rancher on Bare Metal Cloud. Deploy Kubernetes clusters using a few API calls.<br> <br> <span class='pnap-api-knowledge-base-link'> Knowledge base articles to help you can be found <a href='https://phoenixnap.com/kb/rancher-bmc-integration-kubernetes' target='_blank'>here</a> </span><br> <br> <b>All URLs are relative to (https://api.phoenixnap.com/solutions/rancher/v1beta)</b>
7
+
8
+ The version of the OpenAPI document: 0.1
9
+ Contact: support@phoenixnap.com
10
+ Generated by: https://openapi-generator.tech
11
+ OpenAPI Generator version: 5.4.0
12
+
13
+ =end
14
+
15
+ $:.push File.expand_path("../lib", __FILE__)
16
+ require "pnap_rancher_api/version"
17
+
18
+ Gem::Specification.new do |s|
19
+ s.name = "pnap_rancher_api"
20
+ s.version = RancherApi::VERSION
21
+ s.platform = Gem::Platform::RUBY
22
+ s.authors = ["PhoenixNAP"]
23
+ s.email = ["support@phoenixnap.com"]
24
+ s.homepage = "https://phoenixnap.com/bare-metal-cloud"
25
+ s.summary = "Rancher Solution API Ruby Gem"
26
+ s.description = "Rancher Solution API Ruby Gem"
27
+ s.license = "MPL-2.0"
28
+ s.required_ruby_version = ">= 2.4"
29
+ s.metadata = { "source_code_uri" => "https://github.com/phoenixnap/ruby-sdk-bmc-poc" }
30
+
31
+ s.add_runtime_dependency 'typhoeus', '~> 1.0', '>= 1.0.1'
32
+
33
+ s.add_development_dependency 'rspec', '~> 3.6', '>= 3.6.0'
34
+
35
+ s.files = `find *`.split("\n").uniq.sort.select { |f| !f.empty? }
36
+ s.test_files = `find spec/*`.split("\n")
37
+ s.executables = []
38
+ s.require_paths = ["lib"]
39
+ end