pulp_ansible_client 0.11.0.dev1636341492 → 0.11.0.dev1636686953

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of pulp_ansible_client might be problematic. Click here for more details.

@@ -15,37 +15,34 @@ require 'date'
15
15
  module PulpAnsibleClient
16
16
  # A serializer for Git Collection Remotes.
17
17
  class AnsibleGitRemote
18
- attr_accessor :pulp_labels
19
-
20
- # The password to be used for authentication when syncing.
21
- attr_accessor :password
22
-
23
18
  # The URL of an external content source.
24
19
  attr_accessor :url
25
20
 
26
- # A PEM encoded CA certificate used to validate the server certificate presented by the remote server.
27
- attr_accessor :ca_cert
21
+ # The proxy URL. Format: scheme://host:port
22
+ attr_accessor :proxy_url
28
23
 
29
- # Total number of simultaneous connections. If not set then the default value will be used.
30
- attr_accessor :download_concurrency
24
+ # The username to be used for authentication when syncing.
25
+ attr_accessor :username
31
26
 
32
- # Headers for aiohttp.Clientsession
33
- attr_accessor :headers
27
+ # The username to authenticte to the proxy.
28
+ attr_accessor :proxy_username
34
29
 
35
- # A PEM encoded private key used for authentication.
36
- attr_accessor :client_key
30
+ # If True, TLS peer validation must be performed.
31
+ attr_accessor :tls_validation
37
32
 
38
- # A unique name for this remote.
39
- attr_accessor :name
33
+ # The password to be used for authentication when syncing.
34
+ attr_accessor :password
40
35
 
41
36
  # A PEM encoded client certificate used for authentication.
42
37
  attr_accessor :client_cert
43
38
 
44
- # If True, TLS peer validation must be performed.
45
- attr_accessor :tls_validation
39
+ # The password to authenticte to the proxy.
40
+ attr_accessor :proxy_password
46
41
 
47
- # Maximum number of retry attempts after a download failure. If not set then the default value (3) will be used.
48
- attr_accessor :max_retries
42
+ # A PEM encoded private key used for authentication.
43
+ attr_accessor :client_key
44
+
45
+ attr_accessor :pulp_labels
49
46
 
50
47
  # aiohttp.ClientTimeout.sock_read (q.v.) for download-connections. The default is null, which will cause the default from the aiohttp library to be used.
51
48
  attr_accessor :sock_read_timeout
@@ -53,53 +50,56 @@ module PulpAnsibleClient
53
50
  # aiohttp.ClientTimeout.connect (q.v.) for download-connections. The default is null, which will cause the default from the aiohttp library to be used.
54
51
  attr_accessor :connect_timeout
55
52
 
56
- # aiohttp.ClientTimeout.total (q.v.) for download-connections. The default is null, which will cause the default from the aiohttp library to be used.
57
- attr_accessor :total_timeout
53
+ # aiohttp.ClientTimeout.sock_connect (q.v.) for download-connections. The default is null, which will cause the default from the aiohttp library to be used.
54
+ attr_accessor :sock_connect_timeout
58
55
 
59
- # The password to authenticte to the proxy.
60
- attr_accessor :proxy_password
56
+ # A unique name for this remote.
57
+ attr_accessor :name
61
58
 
62
- # The username to authenticte to the proxy.
63
- attr_accessor :proxy_username
59
+ # Headers for aiohttp.Clientsession
60
+ attr_accessor :headers
64
61
 
65
- # The username to be used for authentication when syncing.
66
- attr_accessor :username
62
+ # Total number of simultaneous connections. If not set then the default value will be used.
63
+ attr_accessor :download_concurrency
67
64
 
68
- # aiohttp.ClientTimeout.sock_connect (q.v.) for download-connections. The default is null, which will cause the default from the aiohttp library to be used.
69
- attr_accessor :sock_connect_timeout
65
+ # Maximum number of retry attempts after a download failure. If not set then the default value (3) will be used.
66
+ attr_accessor :max_retries
67
+
68
+ # aiohttp.ClientTimeout.total (q.v.) for download-connections. The default is null, which will cause the default from the aiohttp library to be used.
69
+ attr_accessor :total_timeout
70
+
71
+ # A PEM encoded CA certificate used to validate the server certificate presented by the remote server.
72
+ attr_accessor :ca_cert
70
73
 
71
74
  # Limits total download rate in requests per second
72
75
  attr_accessor :rate_limit
73
76
 
74
- # The proxy URL. Format: scheme://host:port
75
- attr_accessor :proxy_url
76
-
77
77
  # If True, only metadata about the content will be stored in Pulp. Clients will retrieve content from the remote URL.
78
78
  attr_accessor :metadata_only
79
79
 
80
80
  # Attribute mapping from ruby-style variable name to JSON key.
81
81
  def self.attribute_map
82
82
  {
83
- :'pulp_labels' => :'pulp_labels',
84
- :'password' => :'password',
85
83
  :'url' => :'url',
86
- :'ca_cert' => :'ca_cert',
87
- :'download_concurrency' => :'download_concurrency',
88
- :'headers' => :'headers',
89
- :'client_key' => :'client_key',
90
- :'name' => :'name',
91
- :'client_cert' => :'client_cert',
84
+ :'proxy_url' => :'proxy_url',
85
+ :'username' => :'username',
86
+ :'proxy_username' => :'proxy_username',
92
87
  :'tls_validation' => :'tls_validation',
93
- :'max_retries' => :'max_retries',
88
+ :'password' => :'password',
89
+ :'client_cert' => :'client_cert',
90
+ :'proxy_password' => :'proxy_password',
91
+ :'client_key' => :'client_key',
92
+ :'pulp_labels' => :'pulp_labels',
94
93
  :'sock_read_timeout' => :'sock_read_timeout',
95
94
  :'connect_timeout' => :'connect_timeout',
96
- :'total_timeout' => :'total_timeout',
97
- :'proxy_password' => :'proxy_password',
98
- :'proxy_username' => :'proxy_username',
99
- :'username' => :'username',
100
95
  :'sock_connect_timeout' => :'sock_connect_timeout',
96
+ :'name' => :'name',
97
+ :'headers' => :'headers',
98
+ :'download_concurrency' => :'download_concurrency',
99
+ :'max_retries' => :'max_retries',
100
+ :'total_timeout' => :'total_timeout',
101
+ :'ca_cert' => :'ca_cert',
101
102
  :'rate_limit' => :'rate_limit',
102
- :'proxy_url' => :'proxy_url',
103
103
  :'metadata_only' => :'metadata_only'
104
104
  }
105
105
  end
@@ -107,26 +107,26 @@ module PulpAnsibleClient
107
107
  # Attribute type mapping.
108
108
  def self.openapi_types
109
109
  {
110
- :'pulp_labels' => :'Object',
111
- :'password' => :'String',
112
110
  :'url' => :'String',
113
- :'ca_cert' => :'String',
114
- :'download_concurrency' => :'Integer',
115
- :'headers' => :'Array<Object>',
116
- :'client_key' => :'String',
117
- :'name' => :'String',
118
- :'client_cert' => :'String',
111
+ :'proxy_url' => :'String',
112
+ :'username' => :'String',
113
+ :'proxy_username' => :'String',
119
114
  :'tls_validation' => :'Boolean',
120
- :'max_retries' => :'Integer',
115
+ :'password' => :'String',
116
+ :'client_cert' => :'String',
117
+ :'proxy_password' => :'String',
118
+ :'client_key' => :'String',
119
+ :'pulp_labels' => :'Object',
121
120
  :'sock_read_timeout' => :'Float',
122
121
  :'connect_timeout' => :'Float',
123
- :'total_timeout' => :'Float',
124
- :'proxy_password' => :'String',
125
- :'proxy_username' => :'String',
126
- :'username' => :'String',
127
122
  :'sock_connect_timeout' => :'Float',
123
+ :'name' => :'String',
124
+ :'headers' => :'Array<Object>',
125
+ :'download_concurrency' => :'Integer',
126
+ :'max_retries' => :'Integer',
127
+ :'total_timeout' => :'Float',
128
+ :'ca_cert' => :'String',
128
129
  :'rate_limit' => :'Integer',
129
- :'proxy_url' => :'String',
130
130
  :'metadata_only' => :'Boolean'
131
131
  }
132
132
  end
@@ -134,21 +134,21 @@ module PulpAnsibleClient
134
134
  # List of attributes with nullable: true
135
135
  def self.openapi_nullable
136
136
  Set.new([
137
+ :'proxy_url',
138
+ :'username',
139
+ :'proxy_username',
137
140
  :'password',
138
- :'ca_cert',
139
- :'download_concurrency',
140
- :'client_key',
141
141
  :'client_cert',
142
- :'max_retries',
142
+ :'proxy_password',
143
+ :'client_key',
143
144
  :'sock_read_timeout',
144
145
  :'connect_timeout',
145
- :'total_timeout',
146
- :'proxy_password',
147
- :'proxy_username',
148
- :'username',
149
146
  :'sock_connect_timeout',
147
+ :'download_concurrency',
148
+ :'max_retries',
149
+ :'total_timeout',
150
+ :'ca_cert',
150
151
  :'rate_limit',
151
- :'proxy_url',
152
152
  ])
153
153
  end
154
154
 
@@ -167,50 +167,44 @@ module PulpAnsibleClient
167
167
  h[k.to_sym] = v
168
168
  }
169
169
 
170
- if attributes.key?(:'pulp_labels')
171
- self.pulp_labels = attributes[:'pulp_labels']
172
- end
173
-
174
- if attributes.key?(:'password')
175
- self.password = attributes[:'password']
176
- end
177
-
178
170
  if attributes.key?(:'url')
179
171
  self.url = attributes[:'url']
180
172
  end
181
173
 
182
- if attributes.key?(:'ca_cert')
183
- self.ca_cert = attributes[:'ca_cert']
174
+ if attributes.key?(:'proxy_url')
175
+ self.proxy_url = attributes[:'proxy_url']
184
176
  end
185
177
 
186
- if attributes.key?(:'download_concurrency')
187
- self.download_concurrency = attributes[:'download_concurrency']
178
+ if attributes.key?(:'username')
179
+ self.username = attributes[:'username']
188
180
  end
189
181
 
190
- if attributes.key?(:'headers')
191
- if (value = attributes[:'headers']).is_a?(Array)
192
- self.headers = value
193
- end
182
+ if attributes.key?(:'proxy_username')
183
+ self.proxy_username = attributes[:'proxy_username']
194
184
  end
195
185
 
196
- if attributes.key?(:'client_key')
197
- self.client_key = attributes[:'client_key']
186
+ if attributes.key?(:'tls_validation')
187
+ self.tls_validation = attributes[:'tls_validation']
198
188
  end
199
189
 
200
- if attributes.key?(:'name')
201
- self.name = attributes[:'name']
190
+ if attributes.key?(:'password')
191
+ self.password = attributes[:'password']
202
192
  end
203
193
 
204
194
  if attributes.key?(:'client_cert')
205
195
  self.client_cert = attributes[:'client_cert']
206
196
  end
207
197
 
208
- if attributes.key?(:'tls_validation')
209
- self.tls_validation = attributes[:'tls_validation']
198
+ if attributes.key?(:'proxy_password')
199
+ self.proxy_password = attributes[:'proxy_password']
210
200
  end
211
201
 
212
- if attributes.key?(:'max_retries')
213
- self.max_retries = attributes[:'max_retries']
202
+ if attributes.key?(:'client_key')
203
+ self.client_key = attributes[:'client_key']
204
+ end
205
+
206
+ if attributes.key?(:'pulp_labels')
207
+ self.pulp_labels = attributes[:'pulp_labels']
214
208
  end
215
209
 
216
210
  if attributes.key?(:'sock_read_timeout')
@@ -221,32 +215,38 @@ module PulpAnsibleClient
221
215
  self.connect_timeout = attributes[:'connect_timeout']
222
216
  end
223
217
 
224
- if attributes.key?(:'total_timeout')
225
- self.total_timeout = attributes[:'total_timeout']
218
+ if attributes.key?(:'sock_connect_timeout')
219
+ self.sock_connect_timeout = attributes[:'sock_connect_timeout']
226
220
  end
227
221
 
228
- if attributes.key?(:'proxy_password')
229
- self.proxy_password = attributes[:'proxy_password']
222
+ if attributes.key?(:'name')
223
+ self.name = attributes[:'name']
230
224
  end
231
225
 
232
- if attributes.key?(:'proxy_username')
233
- self.proxy_username = attributes[:'proxy_username']
226
+ if attributes.key?(:'headers')
227
+ if (value = attributes[:'headers']).is_a?(Array)
228
+ self.headers = value
229
+ end
234
230
  end
235
231
 
236
- if attributes.key?(:'username')
237
- self.username = attributes[:'username']
232
+ if attributes.key?(:'download_concurrency')
233
+ self.download_concurrency = attributes[:'download_concurrency']
238
234
  end
239
235
 
240
- if attributes.key?(:'sock_connect_timeout')
241
- self.sock_connect_timeout = attributes[:'sock_connect_timeout']
236
+ if attributes.key?(:'max_retries')
237
+ self.max_retries = attributes[:'max_retries']
242
238
  end
243
239
 
244
- if attributes.key?(:'rate_limit')
245
- self.rate_limit = attributes[:'rate_limit']
240
+ if attributes.key?(:'total_timeout')
241
+ self.total_timeout = attributes[:'total_timeout']
246
242
  end
247
243
 
248
- if attributes.key?(:'proxy_url')
249
- self.proxy_url = attributes[:'proxy_url']
244
+ if attributes.key?(:'ca_cert')
245
+ self.ca_cert = attributes[:'ca_cert']
246
+ end
247
+
248
+ if attributes.key?(:'rate_limit')
249
+ self.rate_limit = attributes[:'rate_limit']
250
250
  end
251
251
 
252
252
  if attributes.key?(:'metadata_only')
@@ -262,14 +262,6 @@ module PulpAnsibleClient
262
262
  invalid_properties.push('invalid value for "url", url cannot be nil.')
263
263
  end
264
264
 
265
- if !@download_concurrency.nil? && @download_concurrency < 1
266
- invalid_properties.push('invalid value for "download_concurrency", must be greater than or equal to 1.')
267
- end
268
-
269
- if @name.nil?
270
- invalid_properties.push('invalid value for "name", name cannot be nil.')
271
- end
272
-
273
265
  if !@sock_read_timeout.nil? && @sock_read_timeout < 0.0
274
266
  invalid_properties.push('invalid value for "sock_read_timeout", must be greater than or equal to 0.0.')
275
267
  end
@@ -278,14 +270,22 @@ module PulpAnsibleClient
278
270
  invalid_properties.push('invalid value for "connect_timeout", must be greater than or equal to 0.0.')
279
271
  end
280
272
 
281
- if !@total_timeout.nil? && @total_timeout < 0.0
282
- invalid_properties.push('invalid value for "total_timeout", must be greater than or equal to 0.0.')
283
- end
284
-
285
273
  if !@sock_connect_timeout.nil? && @sock_connect_timeout < 0.0
286
274
  invalid_properties.push('invalid value for "sock_connect_timeout", must be greater than or equal to 0.0.')
287
275
  end
288
276
 
277
+ if @name.nil?
278
+ invalid_properties.push('invalid value for "name", name cannot be nil.')
279
+ end
280
+
281
+ if !@download_concurrency.nil? && @download_concurrency < 1
282
+ invalid_properties.push('invalid value for "download_concurrency", must be greater than or equal to 1.')
283
+ end
284
+
285
+ if !@total_timeout.nil? && @total_timeout < 0.0
286
+ invalid_properties.push('invalid value for "total_timeout", must be greater than or equal to 0.0.')
287
+ end
288
+
289
289
  invalid_properties
290
290
  end
291
291
 
@@ -293,25 +293,15 @@ module PulpAnsibleClient
293
293
  # @return true if the model is valid
294
294
  def valid?
295
295
  return false if @url.nil?
296
- return false if !@download_concurrency.nil? && @download_concurrency < 1
297
- return false if @name.nil?
298
296
  return false if !@sock_read_timeout.nil? && @sock_read_timeout < 0.0
299
297
  return false if !@connect_timeout.nil? && @connect_timeout < 0.0
300
- return false if !@total_timeout.nil? && @total_timeout < 0.0
301
298
  return false if !@sock_connect_timeout.nil? && @sock_connect_timeout < 0.0
299
+ return false if @name.nil?
300
+ return false if !@download_concurrency.nil? && @download_concurrency < 1
301
+ return false if !@total_timeout.nil? && @total_timeout < 0.0
302
302
  true
303
303
  end
304
304
 
305
- # Custom attribute writer method with validation
306
- # @param [Object] download_concurrency Value to be assigned
307
- def download_concurrency=(download_concurrency)
308
- if !download_concurrency.nil? && download_concurrency < 1
309
- fail ArgumentError, 'invalid value for "download_concurrency", must be greater than or equal to 1.'
310
- end
311
-
312
- @download_concurrency = download_concurrency
313
- end
314
-
315
305
  # Custom attribute writer method with validation
316
306
  # @param [Object] sock_read_timeout Value to be assigned
317
307
  def sock_read_timeout=(sock_read_timeout)
@@ -332,16 +322,6 @@ module PulpAnsibleClient
332
322
  @connect_timeout = connect_timeout
333
323
  end
334
324
 
335
- # Custom attribute writer method with validation
336
- # @param [Object] total_timeout Value to be assigned
337
- def total_timeout=(total_timeout)
338
- if !total_timeout.nil? && total_timeout < 0.0
339
- fail ArgumentError, 'invalid value for "total_timeout", must be greater than or equal to 0.0.'
340
- end
341
-
342
- @total_timeout = total_timeout
343
- end
344
-
345
325
  # Custom attribute writer method with validation
346
326
  # @param [Object] sock_connect_timeout Value to be assigned
347
327
  def sock_connect_timeout=(sock_connect_timeout)
@@ -352,31 +332,51 @@ module PulpAnsibleClient
352
332
  @sock_connect_timeout = sock_connect_timeout
353
333
  end
354
334
 
335
+ # Custom attribute writer method with validation
336
+ # @param [Object] download_concurrency Value to be assigned
337
+ def download_concurrency=(download_concurrency)
338
+ if !download_concurrency.nil? && download_concurrency < 1
339
+ fail ArgumentError, 'invalid value for "download_concurrency", must be greater than or equal to 1.'
340
+ end
341
+
342
+ @download_concurrency = download_concurrency
343
+ end
344
+
345
+ # Custom attribute writer method with validation
346
+ # @param [Object] total_timeout Value to be assigned
347
+ def total_timeout=(total_timeout)
348
+ if !total_timeout.nil? && total_timeout < 0.0
349
+ fail ArgumentError, 'invalid value for "total_timeout", must be greater than or equal to 0.0.'
350
+ end
351
+
352
+ @total_timeout = total_timeout
353
+ end
354
+
355
355
  # Checks equality by comparing each attribute.
356
356
  # @param [Object] Object to be compared
357
357
  def ==(o)
358
358
  return true if self.equal?(o)
359
359
  self.class == o.class &&
360
- pulp_labels == o.pulp_labels &&
361
- password == o.password &&
362
360
  url == o.url &&
363
- ca_cert == o.ca_cert &&
364
- download_concurrency == o.download_concurrency &&
365
- headers == o.headers &&
366
- client_key == o.client_key &&
367
- name == o.name &&
368
- client_cert == o.client_cert &&
361
+ proxy_url == o.proxy_url &&
362
+ username == o.username &&
363
+ proxy_username == o.proxy_username &&
369
364
  tls_validation == o.tls_validation &&
370
- max_retries == o.max_retries &&
365
+ password == o.password &&
366
+ client_cert == o.client_cert &&
367
+ proxy_password == o.proxy_password &&
368
+ client_key == o.client_key &&
369
+ pulp_labels == o.pulp_labels &&
371
370
  sock_read_timeout == o.sock_read_timeout &&
372
371
  connect_timeout == o.connect_timeout &&
373
- total_timeout == o.total_timeout &&
374
- proxy_password == o.proxy_password &&
375
- proxy_username == o.proxy_username &&
376
- username == o.username &&
377
372
  sock_connect_timeout == o.sock_connect_timeout &&
373
+ name == o.name &&
374
+ headers == o.headers &&
375
+ download_concurrency == o.download_concurrency &&
376
+ max_retries == o.max_retries &&
377
+ total_timeout == o.total_timeout &&
378
+ ca_cert == o.ca_cert &&
378
379
  rate_limit == o.rate_limit &&
379
- proxy_url == o.proxy_url &&
380
380
  metadata_only == o.metadata_only
381
381
  end
382
382
 
@@ -389,7 +389,7 @@ module PulpAnsibleClient
389
389
  # Calculates hash code according to all attributes.
390
390
  # @return [Integer] Hash code
391
391
  def hash
392
- [pulp_labels, password, url, ca_cert, download_concurrency, headers, client_key, name, client_cert, tls_validation, max_retries, sock_read_timeout, connect_timeout, total_timeout, proxy_password, proxy_username, username, sock_connect_timeout, rate_limit, proxy_url, metadata_only].hash
392
+ [url, proxy_url, username, proxy_username, tls_validation, password, client_cert, proxy_password, client_key, pulp_labels, sock_read_timeout, connect_timeout, sock_connect_timeout, name, headers, download_concurrency, max_retries, total_timeout, ca_cert, rate_limit, metadata_only].hash
393
393
  end
394
394
 
395
395
  # Builds the object from hash