pulpcore_client 3.60.0 → 3.62.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +6 -4
- data/docs/ArtifactDistributionResponse.md +12 -12
- data/docs/DomainBackendMigrator.md +19 -0
- data/docs/DomainsApi.md +54 -0
- data/docs/PatchedUpstreamPulp.md +2 -2
- data/docs/PublicationsApi.md +2 -2
- data/docs/RepositoryVersionsApi.md +2 -2
- data/docs/UpstreamPulp.md +2 -2
- data/docs/UpstreamPulpResponse.md +2 -2
- data/docs/UpstreamPulpsApi.md +56 -0
- data/lib/pulpcore_client/api/domains_api.rb +64 -0
- data/lib/pulpcore_client/api/publications_api.rb +3 -3
- data/lib/pulpcore_client/api/repository_versions_api.rb +3 -3
- data/lib/pulpcore_client/api/upstream_pulps_api.rb +88 -0
- data/lib/pulpcore_client/models/artifact_distribution_response.rb +50 -50
- data/lib/pulpcore_client/models/domain_backend_migrator.rb +228 -0
- data/lib/pulpcore_client/models/patched_upstream_pulp.rb +9 -9
- data/lib/pulpcore_client/models/upstream_pulp.rb +9 -9
- data/lib/pulpcore_client/models/upstream_pulp_response.rb +9 -9
- data/lib/pulpcore_client/version.rb +1 -1
- data/lib/pulpcore_client.rb +1 -0
- data/spec/api/domains_api_spec.rb +12 -0
- data/spec/api/publications_api_spec.rb +1 -1
- data/spec/api/repository_versions_api_spec.rb +1 -1
- data/spec/api/upstream_pulps_api_spec.rb +28 -0
- data/spec/models/artifact_distribution_response_spec.rb +10 -10
- data/spec/models/domain_backend_migrator_spec.rb +47 -0
- data/spec/models/patched_upstream_pulp_spec.rb +1 -1
- data/spec/models/upstream_pulp_response_spec.rb +1 -1
- data/spec/models/upstream_pulp_spec.rb +1 -1
- metadata +156 -152
@@ -216,8 +216,36 @@ module PulpcoreClient
|
|
216
216
|
# List upstream pulps
|
217
217
|
# API for configuring an upstream Pulp to replicate. This API is provided as a tech preview.
|
218
218
|
# @param [Hash] opts the optional parameters
|
219
|
+
# @option opts [String] :base_url Filter results where base_url matches value
|
220
|
+
# @option opts [String] :base_url__contains Filter results where base_url contains value
|
221
|
+
# @option opts [String] :base_url__icontains Filter results where base_url contains value
|
222
|
+
# @option opts [String] :base_url__iexact Filter results where base_url matches value
|
223
|
+
# @option opts [Array<String>] :base_url__in Filter results where base_url is in a comma-separated list of values
|
224
|
+
# @option opts [String] :base_url__iregex Filter results where base_url matches regex value
|
225
|
+
# @option opts [String] :base_url__istartswith Filter results where base_url starts with value
|
226
|
+
# @option opts [String] :base_url__regex Filter results where base_url matches regex value
|
227
|
+
# @option opts [String] :base_url__startswith Filter results where base_url starts with value
|
228
|
+
# @option opts [DateTime] :last_replication Filter results where last_replication matches value
|
229
|
+
# @option opts [DateTime] :last_replication__gt Filter results where last_replication is greater than value
|
230
|
+
# @option opts [DateTime] :last_replication__gte Filter results where last_replication is greater than or equal to value
|
231
|
+
# @option opts [DateTime] :last_replication__lt Filter results where last_replication is less than value
|
232
|
+
# @option opts [DateTime] :last_replication__lte Filter results where last_replication is less than or equal to value
|
233
|
+
# @option opts [Array<DateTime>] :last_replication__range Filter results where last_replication is between two comma separated values
|
219
234
|
# @option opts [Integer] :limit Number of results to return per page.
|
235
|
+
# @option opts [String] :name Filter results where name matches value
|
236
|
+
# @option opts [String] :name__contains Filter results where name contains value
|
237
|
+
# @option opts [String] :name__icontains Filter results where name contains value
|
238
|
+
# @option opts [String] :name__iexact Filter results where name matches value
|
239
|
+
# @option opts [Array<String>] :name__in Filter results where name is in a comma-separated list of values
|
240
|
+
# @option opts [String] :name__iregex Filter results where name matches regex value
|
241
|
+
# @option opts [String] :name__istartswith Filter results where name starts with value
|
242
|
+
# @option opts [String] :name__regex Filter results where name matches regex value
|
243
|
+
# @option opts [String] :name__startswith Filter results where name starts with value
|
220
244
|
# @option opts [Integer] :offset The initial index from which to return the results.
|
245
|
+
# @option opts [Array<String>] :ordering Ordering * `pulp_id` - Pulp id * `-pulp_id` - Pulp id (descending) * `pulp_created` - Pulp created * `-pulp_created` - Pulp created (descending) * `pulp_last_updated` - Pulp last updated * `-pulp_last_updated` - Pulp last updated (descending) * `name` - Name * `-name` - Name (descending) * `base_url` - Base url * `-base_url` - Base url (descending) * `api_root` - Api root * `-api_root` - Api root (descending) * `domain` - Domain * `-domain` - Domain (descending) * `ca_cert` - Ca cert * `-ca_cert` - Ca cert (descending) * `client_cert` - Client cert * `-client_cert` - Client cert (descending) * `client_key` - Client key * `-client_key` - Client key (descending) * `tls_validation` - Tls validation * `-tls_validation` - Tls validation (descending) * `username` - Username * `-username` - Username (descending) * `password` - Password * `-password` - Password (descending) * `pulp_label_select` - Pulp label select * `-pulp_label_select` - Pulp label select (descending) * `q_select` - Q select * `-q_select` - Q select (descending) * `last_replication` - Last replication * `-last_replication` - Last replication (descending) * `pk` - Pk * `-pk` - Pk (descending)
|
246
|
+
# @option opts [Array<String>] :pulp_href__in Multiple values may be separated by commas.
|
247
|
+
# @option opts [Array<String>] :pulp_id__in Multiple values may be separated by commas.
|
248
|
+
# @option opts [String] :q Filter results by using NOT, AND and OR operations on other filters
|
221
249
|
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
222
250
|
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
223
251
|
# @return [PaginatedUpstreamPulpResponseList]
|
@@ -229,8 +257,36 @@ module PulpcoreClient
|
|
229
257
|
# List upstream pulps
|
230
258
|
# API for configuring an upstream Pulp to replicate. This API is provided as a tech preview.
|
231
259
|
# @param [Hash] opts the optional parameters
|
260
|
+
# @option opts [String] :base_url Filter results where base_url matches value
|
261
|
+
# @option opts [String] :base_url__contains Filter results where base_url contains value
|
262
|
+
# @option opts [String] :base_url__icontains Filter results where base_url contains value
|
263
|
+
# @option opts [String] :base_url__iexact Filter results where base_url matches value
|
264
|
+
# @option opts [Array<String>] :base_url__in Filter results where base_url is in a comma-separated list of values
|
265
|
+
# @option opts [String] :base_url__iregex Filter results where base_url matches regex value
|
266
|
+
# @option opts [String] :base_url__istartswith Filter results where base_url starts with value
|
267
|
+
# @option opts [String] :base_url__regex Filter results where base_url matches regex value
|
268
|
+
# @option opts [String] :base_url__startswith Filter results where base_url starts with value
|
269
|
+
# @option opts [DateTime] :last_replication Filter results where last_replication matches value
|
270
|
+
# @option opts [DateTime] :last_replication__gt Filter results where last_replication is greater than value
|
271
|
+
# @option opts [DateTime] :last_replication__gte Filter results where last_replication is greater than or equal to value
|
272
|
+
# @option opts [DateTime] :last_replication__lt Filter results where last_replication is less than value
|
273
|
+
# @option opts [DateTime] :last_replication__lte Filter results where last_replication is less than or equal to value
|
274
|
+
# @option opts [Array<DateTime>] :last_replication__range Filter results where last_replication is between two comma separated values
|
232
275
|
# @option opts [Integer] :limit Number of results to return per page.
|
276
|
+
# @option opts [String] :name Filter results where name matches value
|
277
|
+
# @option opts [String] :name__contains Filter results where name contains value
|
278
|
+
# @option opts [String] :name__icontains Filter results where name contains value
|
279
|
+
# @option opts [String] :name__iexact Filter results where name matches value
|
280
|
+
# @option opts [Array<String>] :name__in Filter results where name is in a comma-separated list of values
|
281
|
+
# @option opts [String] :name__iregex Filter results where name matches regex value
|
282
|
+
# @option opts [String] :name__istartswith Filter results where name starts with value
|
283
|
+
# @option opts [String] :name__regex Filter results where name matches regex value
|
284
|
+
# @option opts [String] :name__startswith Filter results where name starts with value
|
233
285
|
# @option opts [Integer] :offset The initial index from which to return the results.
|
286
|
+
# @option opts [Array<String>] :ordering Ordering * `pulp_id` - Pulp id * `-pulp_id` - Pulp id (descending) * `pulp_created` - Pulp created * `-pulp_created` - Pulp created (descending) * `pulp_last_updated` - Pulp last updated * `-pulp_last_updated` - Pulp last updated (descending) * `name` - Name * `-name` - Name (descending) * `base_url` - Base url * `-base_url` - Base url (descending) * `api_root` - Api root * `-api_root` - Api root (descending) * `domain` - Domain * `-domain` - Domain (descending) * `ca_cert` - Ca cert * `-ca_cert` - Ca cert (descending) * `client_cert` - Client cert * `-client_cert` - Client cert (descending) * `client_key` - Client key * `-client_key` - Client key (descending) * `tls_validation` - Tls validation * `-tls_validation` - Tls validation (descending) * `username` - Username * `-username` - Username (descending) * `password` - Password * `-password` - Password (descending) * `pulp_label_select` - Pulp label select * `-pulp_label_select` - Pulp label select (descending) * `q_select` - Q select * `-q_select` - Q select (descending) * `last_replication` - Last replication * `-last_replication` - Last replication (descending) * `pk` - Pk * `-pk` - Pk (descending)
|
287
|
+
# @option opts [Array<String>] :pulp_href__in Multiple values may be separated by commas.
|
288
|
+
# @option opts [Array<String>] :pulp_id__in Multiple values may be separated by commas.
|
289
|
+
# @option opts [String] :q Filter results by using NOT, AND and OR operations on other filters
|
234
290
|
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
235
291
|
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
236
292
|
# @return [Array<(PaginatedUpstreamPulpResponseList, Integer, Hash)>] PaginatedUpstreamPulpResponseList data, response status code and response headers
|
@@ -238,13 +294,45 @@ module PulpcoreClient
|
|
238
294
|
if @api_client.config.debugging
|
239
295
|
@api_client.config.logger.debug 'Calling API: UpstreamPulpsApi.list ...'
|
240
296
|
end
|
297
|
+
allowable_values = ["-api_root", "-base_url", "-ca_cert", "-client_cert", "-client_key", "-domain", "-last_replication", "-name", "-password", "-pk", "-pulp_created", "-pulp_id", "-pulp_label_select", "-pulp_last_updated", "-q_select", "-tls_validation", "-username", "api_root", "base_url", "ca_cert", "client_cert", "client_key", "domain", "last_replication", "name", "password", "pk", "pulp_created", "pulp_id", "pulp_label_select", "pulp_last_updated", "q_select", "tls_validation", "username"]
|
298
|
+
if @api_client.config.client_side_validation && opts[:'ordering'] && !opts[:'ordering'].all? { |item| allowable_values.include?(item) }
|
299
|
+
fail ArgumentError, "invalid value for \"ordering\", must include one of #{allowable_values}"
|
300
|
+
end
|
241
301
|
# resource path
|
242
302
|
local_var_path = '/pulp/api/v3/upstream-pulps/'
|
243
303
|
|
244
304
|
# query parameters
|
245
305
|
query_params = opts[:query_params] || {}
|
306
|
+
query_params[:'base_url'] = opts[:'base_url'] if !opts[:'base_url'].nil?
|
307
|
+
query_params[:'base_url__contains'] = opts[:'base_url__contains'] if !opts[:'base_url__contains'].nil?
|
308
|
+
query_params[:'base_url__icontains'] = opts[:'base_url__icontains'] if !opts[:'base_url__icontains'].nil?
|
309
|
+
query_params[:'base_url__iexact'] = opts[:'base_url__iexact'] if !opts[:'base_url__iexact'].nil?
|
310
|
+
query_params[:'base_url__in'] = @api_client.build_collection_param(opts[:'base_url__in'], :csv) if !opts[:'base_url__in'].nil?
|
311
|
+
query_params[:'base_url__iregex'] = opts[:'base_url__iregex'] if !opts[:'base_url__iregex'].nil?
|
312
|
+
query_params[:'base_url__istartswith'] = opts[:'base_url__istartswith'] if !opts[:'base_url__istartswith'].nil?
|
313
|
+
query_params[:'base_url__regex'] = opts[:'base_url__regex'] if !opts[:'base_url__regex'].nil?
|
314
|
+
query_params[:'base_url__startswith'] = opts[:'base_url__startswith'] if !opts[:'base_url__startswith'].nil?
|
315
|
+
query_params[:'last_replication'] = opts[:'last_replication'] if !opts[:'last_replication'].nil?
|
316
|
+
query_params[:'last_replication__gt'] = opts[:'last_replication__gt'] if !opts[:'last_replication__gt'].nil?
|
317
|
+
query_params[:'last_replication__gte'] = opts[:'last_replication__gte'] if !opts[:'last_replication__gte'].nil?
|
318
|
+
query_params[:'last_replication__lt'] = opts[:'last_replication__lt'] if !opts[:'last_replication__lt'].nil?
|
319
|
+
query_params[:'last_replication__lte'] = opts[:'last_replication__lte'] if !opts[:'last_replication__lte'].nil?
|
320
|
+
query_params[:'last_replication__range'] = @api_client.build_collection_param(opts[:'last_replication__range'], :csv) if !opts[:'last_replication__range'].nil?
|
246
321
|
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
322
|
+
query_params[:'name'] = opts[:'name'] if !opts[:'name'].nil?
|
323
|
+
query_params[:'name__contains'] = opts[:'name__contains'] if !opts[:'name__contains'].nil?
|
324
|
+
query_params[:'name__icontains'] = opts[:'name__icontains'] if !opts[:'name__icontains'].nil?
|
325
|
+
query_params[:'name__iexact'] = opts[:'name__iexact'] if !opts[:'name__iexact'].nil?
|
326
|
+
query_params[:'name__in'] = @api_client.build_collection_param(opts[:'name__in'], :csv) if !opts[:'name__in'].nil?
|
327
|
+
query_params[:'name__iregex'] = opts[:'name__iregex'] if !opts[:'name__iregex'].nil?
|
328
|
+
query_params[:'name__istartswith'] = opts[:'name__istartswith'] if !opts[:'name__istartswith'].nil?
|
329
|
+
query_params[:'name__regex'] = opts[:'name__regex'] if !opts[:'name__regex'].nil?
|
330
|
+
query_params[:'name__startswith'] = opts[:'name__startswith'] if !opts[:'name__startswith'].nil?
|
247
331
|
query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
|
332
|
+
query_params[:'ordering'] = @api_client.build_collection_param(opts[:'ordering'], :csv) if !opts[:'ordering'].nil?
|
333
|
+
query_params[:'pulp_href__in'] = @api_client.build_collection_param(opts[:'pulp_href__in'], :csv) if !opts[:'pulp_href__in'].nil?
|
334
|
+
query_params[:'pulp_id__in'] = @api_client.build_collection_param(opts[:'pulp_id__in'], :csv) if !opts[:'pulp_id__in'].nil?
|
335
|
+
query_params[:'q'] = opts[:'q'] if !opts[:'q'].nil?
|
248
336
|
query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
|
249
337
|
query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :multi) if !opts[:'exclude_fields'].nil?
|
250
338
|
|
@@ -15,63 +15,63 @@ require 'date'
|
|
15
15
|
module PulpcoreClient
|
16
16
|
# A serializer for ArtifactDistribution.
|
17
17
|
class ArtifactDistributionResponse
|
18
|
-
# Timestamp of the last time this resource was updated. Note: for immutable resources - like content, repository versions, and publication - pulp_created and pulp_last_updated dates will be the same.
|
19
|
-
attr_accessor :pulp_last_updated
|
20
|
-
|
21
18
|
attr_accessor :pulp_labels
|
22
19
|
|
23
|
-
attr_accessor :pulp_href
|
24
|
-
|
25
|
-
# An optional content-guard.
|
26
|
-
attr_accessor :content_guard
|
27
|
-
|
28
20
|
# Timestamp since when the distributed content served by this distribution has not changed. If equals to `null`, no guarantee is provided about content changes.
|
29
21
|
attr_accessor :no_content_change_since
|
30
22
|
|
23
|
+
# The URL for accessing the publication as defined by this distribution.
|
24
|
+
attr_accessor :base_url
|
25
|
+
|
31
26
|
# A unique name. Ex, `rawhide` and `stable`.
|
32
27
|
attr_accessor :name
|
33
28
|
|
29
|
+
# Timestamp of creation.
|
30
|
+
attr_accessor :pulp_created
|
31
|
+
|
34
32
|
# The base (relative) path component of the published url. Avoid paths that overlap with other distribution base paths (e.g. \"foo\" and \"foo/bar\")
|
35
33
|
attr_accessor :base_path
|
36
34
|
|
37
|
-
# Timestamp of
|
38
|
-
attr_accessor :
|
35
|
+
# Timestamp of the last time this resource was updated. Note: for immutable resources - like content, repository versions, and publication - pulp_created and pulp_last_updated dates will be the same.
|
36
|
+
attr_accessor :pulp_last_updated
|
37
|
+
|
38
|
+
attr_accessor :pulp_href
|
39
|
+
|
40
|
+
# An optional content-guard.
|
41
|
+
attr_accessor :content_guard
|
39
42
|
|
40
43
|
# Whether this distribution should be shown in the content app.
|
41
44
|
attr_accessor :hidden
|
42
45
|
|
43
|
-
# The URL for accessing the publication as defined by this distribution.
|
44
|
-
attr_accessor :base_url
|
45
|
-
|
46
46
|
# Attribute mapping from ruby-style variable name to JSON key.
|
47
47
|
def self.attribute_map
|
48
48
|
{
|
49
|
-
:'pulp_last_updated' => :'pulp_last_updated',
|
50
49
|
:'pulp_labels' => :'pulp_labels',
|
51
|
-
:'pulp_href' => :'pulp_href',
|
52
|
-
:'content_guard' => :'content_guard',
|
53
50
|
:'no_content_change_since' => :'no_content_change_since',
|
51
|
+
:'base_url' => :'base_url',
|
54
52
|
:'name' => :'name',
|
55
|
-
:'base_path' => :'base_path',
|
56
53
|
:'pulp_created' => :'pulp_created',
|
57
|
-
:'
|
58
|
-
:'
|
54
|
+
:'base_path' => :'base_path',
|
55
|
+
:'pulp_last_updated' => :'pulp_last_updated',
|
56
|
+
:'pulp_href' => :'pulp_href',
|
57
|
+
:'content_guard' => :'content_guard',
|
58
|
+
:'hidden' => :'hidden'
|
59
59
|
}
|
60
60
|
end
|
61
61
|
|
62
62
|
# Attribute type mapping.
|
63
63
|
def self.openapi_types
|
64
64
|
{
|
65
|
-
:'pulp_last_updated' => :'DateTime',
|
66
65
|
:'pulp_labels' => :'Hash<String, String>',
|
67
|
-
:'pulp_href' => :'String',
|
68
|
-
:'content_guard' => :'String',
|
69
66
|
:'no_content_change_since' => :'String',
|
67
|
+
:'base_url' => :'String',
|
70
68
|
:'name' => :'String',
|
71
|
-
:'base_path' => :'String',
|
72
69
|
:'pulp_created' => :'DateTime',
|
73
|
-
:'
|
74
|
-
:'
|
70
|
+
:'base_path' => :'String',
|
71
|
+
:'pulp_last_updated' => :'DateTime',
|
72
|
+
:'pulp_href' => :'String',
|
73
|
+
:'content_guard' => :'String',
|
74
|
+
:'hidden' => :'Boolean'
|
75
75
|
}
|
76
76
|
end
|
77
77
|
|
@@ -97,38 +97,42 @@ module PulpcoreClient
|
|
97
97
|
h[k.to_sym] = v
|
98
98
|
}
|
99
99
|
|
100
|
-
if attributes.key?(:'pulp_last_updated')
|
101
|
-
self.pulp_last_updated = attributes[:'pulp_last_updated']
|
102
|
-
end
|
103
|
-
|
104
100
|
if attributes.key?(:'pulp_labels')
|
105
101
|
if (value = attributes[:'pulp_labels']).is_a?(Hash)
|
106
102
|
self.pulp_labels = value
|
107
103
|
end
|
108
104
|
end
|
109
105
|
|
110
|
-
if attributes.key?(:'pulp_href')
|
111
|
-
self.pulp_href = attributes[:'pulp_href']
|
112
|
-
end
|
113
|
-
|
114
|
-
if attributes.key?(:'content_guard')
|
115
|
-
self.content_guard = attributes[:'content_guard']
|
116
|
-
end
|
117
|
-
|
118
106
|
if attributes.key?(:'no_content_change_since')
|
119
107
|
self.no_content_change_since = attributes[:'no_content_change_since']
|
120
108
|
end
|
121
109
|
|
110
|
+
if attributes.key?(:'base_url')
|
111
|
+
self.base_url = attributes[:'base_url']
|
112
|
+
end
|
113
|
+
|
122
114
|
if attributes.key?(:'name')
|
123
115
|
self.name = attributes[:'name']
|
124
116
|
end
|
125
117
|
|
118
|
+
if attributes.key?(:'pulp_created')
|
119
|
+
self.pulp_created = attributes[:'pulp_created']
|
120
|
+
end
|
121
|
+
|
126
122
|
if attributes.key?(:'base_path')
|
127
123
|
self.base_path = attributes[:'base_path']
|
128
124
|
end
|
129
125
|
|
130
|
-
if attributes.key?(:'
|
131
|
-
self.
|
126
|
+
if attributes.key?(:'pulp_last_updated')
|
127
|
+
self.pulp_last_updated = attributes[:'pulp_last_updated']
|
128
|
+
end
|
129
|
+
|
130
|
+
if attributes.key?(:'pulp_href')
|
131
|
+
self.pulp_href = attributes[:'pulp_href']
|
132
|
+
end
|
133
|
+
|
134
|
+
if attributes.key?(:'content_guard')
|
135
|
+
self.content_guard = attributes[:'content_guard']
|
132
136
|
end
|
133
137
|
|
134
138
|
if attributes.key?(:'hidden')
|
@@ -136,10 +140,6 @@ module PulpcoreClient
|
|
136
140
|
else
|
137
141
|
self.hidden = false
|
138
142
|
end
|
139
|
-
|
140
|
-
if attributes.key?(:'base_url')
|
141
|
-
self.base_url = attributes[:'base_url']
|
142
|
-
end
|
143
143
|
end
|
144
144
|
|
145
145
|
# Show invalid properties with the reasons. Usually used together with valid?
|
@@ -170,16 +170,16 @@ module PulpcoreClient
|
|
170
170
|
def ==(o)
|
171
171
|
return true if self.equal?(o)
|
172
172
|
self.class == o.class &&
|
173
|
-
pulp_last_updated == o.pulp_last_updated &&
|
174
173
|
pulp_labels == o.pulp_labels &&
|
175
|
-
pulp_href == o.pulp_href &&
|
176
|
-
content_guard == o.content_guard &&
|
177
174
|
no_content_change_since == o.no_content_change_since &&
|
175
|
+
base_url == o.base_url &&
|
178
176
|
name == o.name &&
|
179
|
-
base_path == o.base_path &&
|
180
177
|
pulp_created == o.pulp_created &&
|
181
|
-
|
182
|
-
|
178
|
+
base_path == o.base_path &&
|
179
|
+
pulp_last_updated == o.pulp_last_updated &&
|
180
|
+
pulp_href == o.pulp_href &&
|
181
|
+
content_guard == o.content_guard &&
|
182
|
+
hidden == o.hidden
|
183
183
|
end
|
184
184
|
|
185
185
|
# @see the `==` method
|
@@ -191,7 +191,7 @@ module PulpcoreClient
|
|
191
191
|
# Calculates hash code according to all attributes.
|
192
192
|
# @return [Integer] Hash code
|
193
193
|
def hash
|
194
|
-
[
|
194
|
+
[pulp_labels, no_content_change_since, base_url, name, pulp_created, base_path, pulp_last_updated, pulp_href, content_guard, hidden].hash
|
195
195
|
end
|
196
196
|
|
197
197
|
# Builds the object from hash
|
@@ -0,0 +1,228 @@
|
|
1
|
+
=begin
|
2
|
+
#Pulp 3 API
|
3
|
+
|
4
|
+
#Fetch, Upload, Organize, and Distribute Software Packages
|
5
|
+
|
6
|
+
The version of the OpenAPI document: v3
|
7
|
+
Contact: pulp-list@redhat.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
|
15
|
+
module PulpcoreClient
|
16
|
+
# Special serializer for performing a storage backend migration on a Domain.
|
17
|
+
class DomainBackendMigrator
|
18
|
+
# The new backend storage class to migrate to. * `pulpcore.app.models.storage.FileSystem` - Use local filesystem as storage * `storages.backends.s3boto3.S3Boto3Storage` - Use Amazon S3 as storage * `storages.backends.azure_storage.AzureStorage` - Use Azure Blob as storage
|
19
|
+
attr_accessor :storage_class
|
20
|
+
|
21
|
+
# The settings for the new storage class to migrate to.
|
22
|
+
attr_accessor :storage_settings
|
23
|
+
|
24
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
25
|
+
def self.attribute_map
|
26
|
+
{
|
27
|
+
:'storage_class' => :'storage_class',
|
28
|
+
:'storage_settings' => :'storage_settings'
|
29
|
+
}
|
30
|
+
end
|
31
|
+
|
32
|
+
# Attribute type mapping.
|
33
|
+
def self.openapi_types
|
34
|
+
{
|
35
|
+
:'storage_class' => :'StorageClassEnum',
|
36
|
+
:'storage_settings' => :'Object'
|
37
|
+
}
|
38
|
+
end
|
39
|
+
|
40
|
+
# List of attributes with nullable: true
|
41
|
+
def self.openapi_nullable
|
42
|
+
Set.new([
|
43
|
+
])
|
44
|
+
end
|
45
|
+
|
46
|
+
# Initializes the object
|
47
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
48
|
+
def initialize(attributes = {})
|
49
|
+
if (!attributes.is_a?(Hash))
|
50
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `PulpcoreClient::DomainBackendMigrator` initialize method"
|
51
|
+
end
|
52
|
+
|
53
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
54
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
55
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
56
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `PulpcoreClient::DomainBackendMigrator`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
57
|
+
end
|
58
|
+
h[k.to_sym] = v
|
59
|
+
}
|
60
|
+
|
61
|
+
if attributes.key?(:'storage_class')
|
62
|
+
self.storage_class = attributes[:'storage_class']
|
63
|
+
end
|
64
|
+
|
65
|
+
if attributes.key?(:'storage_settings')
|
66
|
+
self.storage_settings = attributes[:'storage_settings']
|
67
|
+
end
|
68
|
+
end
|
69
|
+
|
70
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
71
|
+
# @return Array for valid properties with the reasons
|
72
|
+
def list_invalid_properties
|
73
|
+
invalid_properties = Array.new
|
74
|
+
if @storage_class.nil?
|
75
|
+
invalid_properties.push('invalid value for "storage_class", storage_class cannot be nil.')
|
76
|
+
end
|
77
|
+
|
78
|
+
if @storage_settings.nil?
|
79
|
+
invalid_properties.push('invalid value for "storage_settings", storage_settings cannot be nil.')
|
80
|
+
end
|
81
|
+
|
82
|
+
invalid_properties
|
83
|
+
end
|
84
|
+
|
85
|
+
# Check to see if the all the properties in the model are valid
|
86
|
+
# @return true if the model is valid
|
87
|
+
def valid?
|
88
|
+
return false if @storage_class.nil?
|
89
|
+
return false if @storage_settings.nil?
|
90
|
+
true
|
91
|
+
end
|
92
|
+
|
93
|
+
# Checks equality by comparing each attribute.
|
94
|
+
# @param [Object] Object to be compared
|
95
|
+
def ==(o)
|
96
|
+
return true if self.equal?(o)
|
97
|
+
self.class == o.class &&
|
98
|
+
storage_class == o.storage_class &&
|
99
|
+
storage_settings == o.storage_settings
|
100
|
+
end
|
101
|
+
|
102
|
+
# @see the `==` method
|
103
|
+
# @param [Object] Object to be compared
|
104
|
+
def eql?(o)
|
105
|
+
self == o
|
106
|
+
end
|
107
|
+
|
108
|
+
# Calculates hash code according to all attributes.
|
109
|
+
# @return [Integer] Hash code
|
110
|
+
def hash
|
111
|
+
[storage_class, storage_settings].hash
|
112
|
+
end
|
113
|
+
|
114
|
+
# Builds the object from hash
|
115
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
116
|
+
# @return [Object] Returns the model itself
|
117
|
+
def self.build_from_hash(attributes)
|
118
|
+
new.build_from_hash(attributes)
|
119
|
+
end
|
120
|
+
|
121
|
+
# Builds the object from hash
|
122
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
123
|
+
# @return [Object] Returns the model itself
|
124
|
+
def build_from_hash(attributes)
|
125
|
+
return nil unless attributes.is_a?(Hash)
|
126
|
+
self.class.openapi_types.each_pair do |key, type|
|
127
|
+
if type =~ /\AArray<(.*)>/i
|
128
|
+
# check to ensure the input is an array given that the attribute
|
129
|
+
# is documented as an array but the input is not
|
130
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
131
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
132
|
+
end
|
133
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
134
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
135
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
136
|
+
end
|
137
|
+
|
138
|
+
self
|
139
|
+
end
|
140
|
+
|
141
|
+
# Deserializes the data based on type
|
142
|
+
# @param string type Data type
|
143
|
+
# @param string value Value to be deserialized
|
144
|
+
# @return [Object] Deserialized data
|
145
|
+
def _deserialize(type, value)
|
146
|
+
case type.to_sym
|
147
|
+
when :DateTime
|
148
|
+
DateTime.parse(value)
|
149
|
+
when :Date
|
150
|
+
Date.parse(value)
|
151
|
+
when :String
|
152
|
+
value.to_s
|
153
|
+
when :Integer
|
154
|
+
value.to_i
|
155
|
+
when :Float
|
156
|
+
value.to_f
|
157
|
+
when :Boolean
|
158
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
159
|
+
true
|
160
|
+
else
|
161
|
+
false
|
162
|
+
end
|
163
|
+
when :Object
|
164
|
+
# generic object (usually a Hash), return directly
|
165
|
+
value
|
166
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
167
|
+
inner_type = Regexp.last_match[:inner_type]
|
168
|
+
value.map { |v| _deserialize(inner_type, v) }
|
169
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
170
|
+
k_type = Regexp.last_match[:k_type]
|
171
|
+
v_type = Regexp.last_match[:v_type]
|
172
|
+
{}.tap do |hash|
|
173
|
+
value.each do |k, v|
|
174
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
175
|
+
end
|
176
|
+
end
|
177
|
+
else # model
|
178
|
+
PulpcoreClient.const_get(type).build_from_hash(value)
|
179
|
+
end
|
180
|
+
end
|
181
|
+
|
182
|
+
# Returns the string representation of the object
|
183
|
+
# @return [String] String presentation of the object
|
184
|
+
def to_s
|
185
|
+
to_hash.to_s
|
186
|
+
end
|
187
|
+
|
188
|
+
# to_body is an alias to to_hash (backward compatibility)
|
189
|
+
# @return [Hash] Returns the object in the form of hash
|
190
|
+
def to_body
|
191
|
+
to_hash
|
192
|
+
end
|
193
|
+
|
194
|
+
# Returns the object in the form of hash
|
195
|
+
# @return [Hash] Returns the object in the form of hash
|
196
|
+
def to_hash
|
197
|
+
hash = {}
|
198
|
+
self.class.attribute_map.each_pair do |attr, param|
|
199
|
+
value = self.send(attr)
|
200
|
+
if value.nil?
|
201
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
202
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
203
|
+
end
|
204
|
+
|
205
|
+
hash[param] = _to_hash(value)
|
206
|
+
end
|
207
|
+
hash
|
208
|
+
end
|
209
|
+
|
210
|
+
# Outputs non-array value in the form of hash
|
211
|
+
# For object, use to_hash. Otherwise, just return the value
|
212
|
+
# @param [Object] value Any valid value
|
213
|
+
# @return [Hash] Returns the value in the form of hash
|
214
|
+
def _to_hash(value)
|
215
|
+
if value.is_a?(Array)
|
216
|
+
value.compact.map { |v| _to_hash(v) }
|
217
|
+
elsif value.is_a?(Hash)
|
218
|
+
{}.tap do |hash|
|
219
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
220
|
+
end
|
221
|
+
elsif value.respond_to? :to_hash
|
222
|
+
value.to_hash
|
223
|
+
else
|
224
|
+
value
|
225
|
+
end
|
226
|
+
end
|
227
|
+
end
|
228
|
+
end
|
@@ -45,8 +45,8 @@ module PulpcoreClient
|
|
45
45
|
# The password to be used for authentication when syncing. Extra leading and trailing whitespace characters are not trimmed.
|
46
46
|
attr_accessor :password
|
47
47
|
|
48
|
-
#
|
49
|
-
attr_accessor :
|
48
|
+
# Filter distributions on the upstream Pulp using complex filtering. E.g. pulp_label_select=\"foo\" OR pulp_label_select=\"key=val\"
|
49
|
+
attr_accessor :q_select
|
50
50
|
|
51
51
|
# Attribute mapping from ruby-style variable name to JSON key.
|
52
52
|
def self.attribute_map
|
@@ -61,7 +61,7 @@ module PulpcoreClient
|
|
61
61
|
:'tls_validation' => :'tls_validation',
|
62
62
|
:'username' => :'username',
|
63
63
|
:'password' => :'password',
|
64
|
-
:'
|
64
|
+
:'q_select' => :'q_select'
|
65
65
|
}
|
66
66
|
end
|
67
67
|
|
@@ -78,7 +78,7 @@ module PulpcoreClient
|
|
78
78
|
:'tls_validation' => :'Boolean',
|
79
79
|
:'username' => :'String',
|
80
80
|
:'password' => :'String',
|
81
|
-
:'
|
81
|
+
:'q_select' => :'String'
|
82
82
|
}
|
83
83
|
end
|
84
84
|
|
@@ -91,7 +91,7 @@ module PulpcoreClient
|
|
91
91
|
:'client_key',
|
92
92
|
:'username',
|
93
93
|
:'password',
|
94
|
-
:'
|
94
|
+
:'q_select'
|
95
95
|
])
|
96
96
|
end
|
97
97
|
|
@@ -150,8 +150,8 @@ module PulpcoreClient
|
|
150
150
|
self.password = attributes[:'password']
|
151
151
|
end
|
152
152
|
|
153
|
-
if attributes.key?(:'
|
154
|
-
self.
|
153
|
+
if attributes.key?(:'q_select')
|
154
|
+
self.q_select = attributes[:'q_select']
|
155
155
|
end
|
156
156
|
end
|
157
157
|
|
@@ -318,7 +318,7 @@ module PulpcoreClient
|
|
318
318
|
tls_validation == o.tls_validation &&
|
319
319
|
username == o.username &&
|
320
320
|
password == o.password &&
|
321
|
-
|
321
|
+
q_select == o.q_select
|
322
322
|
end
|
323
323
|
|
324
324
|
# @see the `==` method
|
@@ -330,7 +330,7 @@ module PulpcoreClient
|
|
330
330
|
# Calculates hash code according to all attributes.
|
331
331
|
# @return [Integer] Hash code
|
332
332
|
def hash
|
333
|
-
[name, base_url, api_root, domain, ca_cert, client_cert, client_key, tls_validation, username, password,
|
333
|
+
[name, base_url, api_root, domain, ca_cert, client_cert, client_key, tls_validation, username, password, q_select].hash
|
334
334
|
end
|
335
335
|
|
336
336
|
# Builds the object from hash
|