pulp_container_client 2.3.1 → 2.4.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (62) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +19 -16
  3. data/docs/ContainerContainerDistribution.md +7 -7
  4. data/docs/ContainerContainerDistributionResponse.md +8 -8
  5. data/docs/ContainerContainerRemote.md +7 -1
  6. data/docs/ContainerContainerRemoteResponse.md +3 -7
  7. data/docs/ContentBlobsApi.md +12 -12
  8. data/docs/ContentManifestsApi.md +12 -12
  9. data/docs/ContentTagsApi.md +14 -14
  10. data/docs/{ContentGuardsContentRedirectApi.md → ContentguardsContentRedirectApi.md} +29 -29
  11. data/docs/DistributionsContainerApi.md +22 -22
  12. data/docs/ManifestCopy.md +1 -1
  13. data/docs/MediaTypesEnum.md +16 -0
  14. data/docs/PatchedcontainerContainerDistribution.md +7 -7
  15. data/docs/PatchedcontainerContainerRemote.md +7 -1
  16. data/docs/PulpContainerNamespacesApi.md +10 -10
  17. data/docs/RemotesContainerApi.md +24 -24
  18. data/docs/RemoveImage.md +17 -0
  19. data/docs/RepositoriesContainerApi.md +12 -12
  20. data/docs/RepositoriesContainerPushApi.md +68 -12
  21. data/docs/RepositoriesContainerVersionsApi.md +56 -56
  22. data/lib/pulp_container_client/api/content_blobs_api.rb +14 -14
  23. data/lib/pulp_container_client/api/content_manifests_api.rb +14 -14
  24. data/lib/pulp_container_client/api/content_tags_api.rb +17 -17
  25. data/lib/pulp_container_client/api/{content_guards_content_redirect_api.rb → contentguards_content_redirect_api.rb} +33 -33
  26. data/lib/pulp_container_client/api/distributions_container_api.rb +24 -24
  27. data/lib/pulp_container_client/api/pulp_container_namespaces_api.rb +11 -11
  28. data/lib/pulp_container_client/api/remotes_container_api.rb +26 -26
  29. data/lib/pulp_container_client/api/repositories_container_api.rb +13 -13
  30. data/lib/pulp_container_client/api/repositories_container_push_api.rb +83 -13
  31. data/lib/pulp_container_client/api/repositories_container_versions_api.rb +100 -60
  32. data/lib/pulp_container_client/models/container_container_distribution.rb +36 -36
  33. data/lib/pulp_container_client/models/container_container_distribution_response.rb +40 -40
  34. data/lib/pulp_container_client/models/container_container_remote.rb +36 -2
  35. data/lib/pulp_container_client/models/container_container_remote_response.rb +14 -35
  36. data/lib/pulp_container_client/models/manifest_copy.rb +1 -23
  37. data/lib/pulp_container_client/models/media_types_enum.rb +39 -0
  38. data/lib/pulp_container_client/models/patchedcontainer_container_distribution.rb +31 -31
  39. data/lib/pulp_container_client/models/patchedcontainer_container_remote.rb +36 -2
  40. data/lib/pulp_container_client/models/remove_image.rb +213 -0
  41. data/lib/pulp_container_client/version.rb +1 -1
  42. data/lib/pulp_container_client.rb +3 -1
  43. data/spec/api/content_blobs_api_spec.rb +6 -6
  44. data/spec/api/content_manifests_api_spec.rb +6 -6
  45. data/spec/api/content_tags_api_spec.rb +7 -7
  46. data/spec/api/{content_guards_content_redirect_api_spec.rb → contentguards_content_redirect_api_spec.rb} +11 -11
  47. data/spec/api/distributions_container_api_spec.rb +11 -11
  48. data/spec/api/pulp_container_namespaces_api_spec.rb +5 -5
  49. data/spec/api/remotes_container_api_spec.rb +12 -12
  50. data/spec/api/repositories_container_api_spec.rb +6 -6
  51. data/spec/api/repositories_container_push_api_spec.rb +19 -6
  52. data/spec/api/repositories_container_versions_api_spec.rb +28 -28
  53. data/spec/models/container_container_distribution_response_spec.rb +7 -7
  54. data/spec/models/container_container_distribution_spec.rb +6 -6
  55. data/spec/models/container_container_remote_response_spec.rb +6 -18
  56. data/spec/models/container_container_remote_spec.rb +18 -0
  57. data/spec/models/manifest_copy_spec.rb +0 -4
  58. data/spec/models/media_types_enum_spec.rb +35 -0
  59. data/spec/models/patchedcontainer_container_distribution_spec.rb +6 -6
  60. data/spec/models/patchedcontainer_container_remote_spec.rb +18 -0
  61. data/spec/models/remove_image_spec.rb +41 -0
  62. metadata +53 -45
@@ -15,18 +15,21 @@ require 'date'
15
15
  module PulpContainerClient
16
16
  # A serializer for ContainerDistribution.
17
17
  class ContainerContainerDistributionResponse
18
- # A unique name. Ex, `rawhide` and `stable`.
19
- attr_accessor :name
18
+ attr_accessor :pulp_href
20
19
 
21
20
  attr_accessor :pulp_labels
22
21
 
23
- # The latest RepositoryVersion for this Repository will be served.
24
- attr_accessor :repository
25
-
26
22
  # The base (relative) path component of the published url. Avoid paths that overlap with other distribution base paths (e.g. \"foo\" and \"foo/bar\")
27
23
  attr_accessor :base_path
28
24
 
29
- attr_accessor :pulp_href
25
+ # RepositoryVersion to be served
26
+ attr_accessor :repository_version
27
+
28
+ # A unique name. Ex, `rawhide` and `stable`.
29
+ attr_accessor :name
30
+
31
+ # The latest RepositoryVersion for this Repository will be served.
32
+ attr_accessor :repository
30
33
 
31
34
  # An optional content-guard. If none is specified, a default one will be used.
32
35
  attr_accessor :content_guard
@@ -34,9 +37,6 @@ module PulpContainerClient
34
37
  # Timestamp of creation.
35
38
  attr_accessor :pulp_created
36
39
 
37
- # RepositoryVersion to be served
38
- attr_accessor :repository_version
39
-
40
40
  # The Registry hostame/name/ to use with docker pull command defined by this distribution.
41
41
  attr_accessor :registry_path
42
42
 
@@ -52,14 +52,14 @@ module PulpContainerClient
52
52
  # Attribute mapping from ruby-style variable name to JSON key.
53
53
  def self.attribute_map
54
54
  {
55
- :'name' => :'name',
55
+ :'pulp_href' => :'pulp_href',
56
56
  :'pulp_labels' => :'pulp_labels',
57
- :'repository' => :'repository',
58
57
  :'base_path' => :'base_path',
59
- :'pulp_href' => :'pulp_href',
58
+ :'repository_version' => :'repository_version',
59
+ :'name' => :'name',
60
+ :'repository' => :'repository',
60
61
  :'content_guard' => :'content_guard',
61
62
  :'pulp_created' => :'pulp_created',
62
- :'repository_version' => :'repository_version',
63
63
  :'registry_path' => :'registry_path',
64
64
  :'namespace' => :'namespace',
65
65
  :'private' => :'private',
@@ -70,14 +70,14 @@ module PulpContainerClient
70
70
  # Attribute type mapping.
71
71
  def self.openapi_types
72
72
  {
73
- :'name' => :'String',
73
+ :'pulp_href' => :'String',
74
74
  :'pulp_labels' => :'Object',
75
- :'repository' => :'String',
76
75
  :'base_path' => :'String',
77
- :'pulp_href' => :'String',
76
+ :'repository_version' => :'String',
77
+ :'name' => :'String',
78
+ :'repository' => :'String',
78
79
  :'content_guard' => :'String',
79
80
  :'pulp_created' => :'DateTime',
80
- :'repository_version' => :'String',
81
81
  :'registry_path' => :'String',
82
82
  :'namespace' => :'String',
83
83
  :'private' => :'Boolean',
@@ -88,8 +88,8 @@ module PulpContainerClient
88
88
  # List of attributes with nullable: true
89
89
  def self.openapi_nullable
90
90
  Set.new([
91
- :'repository',
92
91
  :'repository_version',
92
+ :'repository',
93
93
  :'description'
94
94
  ])
95
95
  end
@@ -109,24 +109,28 @@ module PulpContainerClient
109
109
  h[k.to_sym] = v
110
110
  }
111
111
 
112
- if attributes.key?(:'name')
113
- self.name = attributes[:'name']
112
+ if attributes.key?(:'pulp_href')
113
+ self.pulp_href = attributes[:'pulp_href']
114
114
  end
115
115
 
116
116
  if attributes.key?(:'pulp_labels')
117
117
  self.pulp_labels = attributes[:'pulp_labels']
118
118
  end
119
119
 
120
- if attributes.key?(:'repository')
121
- self.repository = attributes[:'repository']
122
- end
123
-
124
120
  if attributes.key?(:'base_path')
125
121
  self.base_path = attributes[:'base_path']
126
122
  end
127
123
 
128
- if attributes.key?(:'pulp_href')
129
- self.pulp_href = attributes[:'pulp_href']
124
+ if attributes.key?(:'repository_version')
125
+ self.repository_version = attributes[:'repository_version']
126
+ end
127
+
128
+ if attributes.key?(:'name')
129
+ self.name = attributes[:'name']
130
+ end
131
+
132
+ if attributes.key?(:'repository')
133
+ self.repository = attributes[:'repository']
130
134
  end
131
135
 
132
136
  if attributes.key?(:'content_guard')
@@ -137,10 +141,6 @@ module PulpContainerClient
137
141
  self.pulp_created = attributes[:'pulp_created']
138
142
  end
139
143
 
140
- if attributes.key?(:'repository_version')
141
- self.repository_version = attributes[:'repository_version']
142
- end
143
-
144
144
  if attributes.key?(:'registry_path')
145
145
  self.registry_path = attributes[:'registry_path']
146
146
  end
@@ -162,22 +162,22 @@ module PulpContainerClient
162
162
  # @return Array for valid properties with the reasons
163
163
  def list_invalid_properties
164
164
  invalid_properties = Array.new
165
- if @name.nil?
166
- invalid_properties.push('invalid value for "name", name cannot be nil.')
167
- end
168
-
169
165
  if @base_path.nil?
170
166
  invalid_properties.push('invalid value for "base_path", base_path cannot be nil.')
171
167
  end
172
168
 
169
+ if @name.nil?
170
+ invalid_properties.push('invalid value for "name", name cannot be nil.')
171
+ end
172
+
173
173
  invalid_properties
174
174
  end
175
175
 
176
176
  # Check to see if the all the properties in the model are valid
177
177
  # @return true if the model is valid
178
178
  def valid?
179
- return false if @name.nil?
180
179
  return false if @base_path.nil?
180
+ return false if @name.nil?
181
181
  true
182
182
  end
183
183
 
@@ -186,14 +186,14 @@ module PulpContainerClient
186
186
  def ==(o)
187
187
  return true if self.equal?(o)
188
188
  self.class == o.class &&
189
- name == o.name &&
189
+ pulp_href == o.pulp_href &&
190
190
  pulp_labels == o.pulp_labels &&
191
- repository == o.repository &&
192
191
  base_path == o.base_path &&
193
- pulp_href == o.pulp_href &&
192
+ repository_version == o.repository_version &&
193
+ name == o.name &&
194
+ repository == o.repository &&
194
195
  content_guard == o.content_guard &&
195
196
  pulp_created == o.pulp_created &&
196
- repository_version == o.repository_version &&
197
197
  registry_path == o.registry_path &&
198
198
  namespace == o.namespace &&
199
199
  private == o.private &&
@@ -209,7 +209,7 @@ module PulpContainerClient
209
209
  # Calculates hash code according to all attributes.
210
210
  # @return [Integer] Hash code
211
211
  def hash
212
- [name, pulp_labels, repository, base_path, pulp_href, content_guard, pulp_created, repository_version, registry_path, namespace, private, description].hash
212
+ [pulp_href, pulp_labels, base_path, repository_version, name, repository, content_guard, pulp_created, registry_path, namespace, private, description].hash
213
213
  end
214
214
 
215
215
  # Builds the object from hash
@@ -33,9 +33,15 @@ module PulpContainerClient
33
33
  # If True, TLS peer validation must be performed.
34
34
  attr_accessor :tls_validation
35
35
 
36
- # The proxy URL. Format: scheme://user:password@host:port
36
+ # The proxy URL. Format: scheme://host:port
37
37
  attr_accessor :proxy_url
38
38
 
39
+ # The username to authenticte to the proxy.
40
+ attr_accessor :proxy_username
41
+
42
+ # The password to authenticte to the proxy.
43
+ attr_accessor :proxy_password
44
+
39
45
  # The username to be used for authentication when syncing.
40
46
  attr_accessor :username
41
47
 
@@ -62,6 +68,9 @@ module PulpContainerClient
62
68
  # aiohttp.ClientTimeout.sock_read (q.v.) for download-connections.
63
69
  attr_accessor :sock_read_timeout
64
70
 
71
+ # Headers for aiohttp.Clientsession
72
+ attr_accessor :headers
73
+
65
74
  # Limits total download rate in requests per second
66
75
  attr_accessor :rate_limit
67
76
 
@@ -84,6 +93,8 @@ module PulpContainerClient
84
93
  :'client_key' => :'client_key',
85
94
  :'tls_validation' => :'tls_validation',
86
95
  :'proxy_url' => :'proxy_url',
96
+ :'proxy_username' => :'proxy_username',
97
+ :'proxy_password' => :'proxy_password',
87
98
  :'username' => :'username',
88
99
  :'password' => :'password',
89
100
  :'pulp_labels' => :'pulp_labels',
@@ -93,6 +104,7 @@ module PulpContainerClient
93
104
  :'connect_timeout' => :'connect_timeout',
94
105
  :'sock_connect_timeout' => :'sock_connect_timeout',
95
106
  :'sock_read_timeout' => :'sock_read_timeout',
107
+ :'headers' => :'headers',
96
108
  :'rate_limit' => :'rate_limit',
97
109
  :'upstream_name' => :'upstream_name',
98
110
  :'include_tags' => :'include_tags',
@@ -110,6 +122,8 @@ module PulpContainerClient
110
122
  :'client_key' => :'String',
111
123
  :'tls_validation' => :'Boolean',
112
124
  :'proxy_url' => :'String',
125
+ :'proxy_username' => :'String',
126
+ :'proxy_password' => :'String',
113
127
  :'username' => :'String',
114
128
  :'password' => :'String',
115
129
  :'pulp_labels' => :'Object',
@@ -119,6 +133,7 @@ module PulpContainerClient
119
133
  :'connect_timeout' => :'Float',
120
134
  :'sock_connect_timeout' => :'Float',
121
135
  :'sock_read_timeout' => :'Float',
136
+ :'headers' => :'Array<Object>',
122
137
  :'rate_limit' => :'Integer',
123
138
  :'upstream_name' => :'String',
124
139
  :'include_tags' => :'Array<String>',
@@ -133,6 +148,8 @@ module PulpContainerClient
133
148
  :'client_cert',
134
149
  :'client_key',
135
150
  :'proxy_url',
151
+ :'proxy_username',
152
+ :'proxy_password',
136
153
  :'username',
137
154
  :'password',
138
155
  :'total_timeout',
@@ -188,6 +205,14 @@ module PulpContainerClient
188
205
  self.proxy_url = attributes[:'proxy_url']
189
206
  end
190
207
 
208
+ if attributes.key?(:'proxy_username')
209
+ self.proxy_username = attributes[:'proxy_username']
210
+ end
211
+
212
+ if attributes.key?(:'proxy_password')
213
+ self.proxy_password = attributes[:'proxy_password']
214
+ end
215
+
191
216
  if attributes.key?(:'username')
192
217
  self.username = attributes[:'username']
193
218
  end
@@ -224,6 +249,12 @@ module PulpContainerClient
224
249
  self.sock_read_timeout = attributes[:'sock_read_timeout']
225
250
  end
226
251
 
252
+ if attributes.key?(:'headers')
253
+ if (value = attributes[:'headers']).is_a?(Array)
254
+ self.headers = value
255
+ end
256
+ end
257
+
227
258
  if attributes.key?(:'rate_limit')
228
259
  self.rate_limit = attributes[:'rate_limit']
229
260
  end
@@ -360,6 +391,8 @@ module PulpContainerClient
360
391
  client_key == o.client_key &&
361
392
  tls_validation == o.tls_validation &&
362
393
  proxy_url == o.proxy_url &&
394
+ proxy_username == o.proxy_username &&
395
+ proxy_password == o.proxy_password &&
363
396
  username == o.username &&
364
397
  password == o.password &&
365
398
  pulp_labels == o.pulp_labels &&
@@ -369,6 +402,7 @@ module PulpContainerClient
369
402
  connect_timeout == o.connect_timeout &&
370
403
  sock_connect_timeout == o.sock_connect_timeout &&
371
404
  sock_read_timeout == o.sock_read_timeout &&
405
+ headers == o.headers &&
372
406
  rate_limit == o.rate_limit &&
373
407
  upstream_name == o.upstream_name &&
374
408
  include_tags == o.include_tags &&
@@ -384,7 +418,7 @@ module PulpContainerClient
384
418
  # Calculates hash code according to all attributes.
385
419
  # @return [Integer] Hash code
386
420
  def hash
387
- [name, url, ca_cert, client_cert, client_key, tls_validation, proxy_url, username, password, pulp_labels, download_concurrency, policy, total_timeout, connect_timeout, sock_connect_timeout, sock_read_timeout, rate_limit, upstream_name, include_tags, exclude_tags].hash
421
+ [name, url, ca_cert, client_cert, client_key, tls_validation, proxy_url, proxy_username, proxy_password, username, password, pulp_labels, download_concurrency, policy, total_timeout, connect_timeout, sock_connect_timeout, sock_read_timeout, headers, rate_limit, upstream_name, include_tags, exclude_tags].hash
388
422
  end
389
423
 
390
424
  # Builds the object from hash
@@ -32,21 +32,12 @@ module PulpContainerClient
32
32
  # A PEM encoded client certificate used for authentication.
33
33
  attr_accessor :client_cert
34
34
 
35
- # A PEM encoded private key used for authentication.
36
- attr_accessor :client_key
37
-
38
35
  # If True, TLS peer validation must be performed.
39
36
  attr_accessor :tls_validation
40
37
 
41
- # The proxy URL. Format: scheme://user:password@host:port
38
+ # The proxy URL. Format: scheme://host:port
42
39
  attr_accessor :proxy_url
43
40
 
44
- # The username to be used for authentication when syncing.
45
- attr_accessor :username
46
-
47
- # The password to be used for authentication when syncing.
48
- attr_accessor :password
49
-
50
41
  attr_accessor :pulp_labels
51
42
 
52
43
  # Timestamp of the most recent update of the remote.
@@ -70,6 +61,9 @@ module PulpContainerClient
70
61
  # aiohttp.ClientTimeout.sock_read (q.v.) for download-connections.
71
62
  attr_accessor :sock_read_timeout
72
63
 
64
+ # Headers for aiohttp.Clientsession
65
+ attr_accessor :headers
66
+
73
67
  # Limits total download rate in requests per second
74
68
  attr_accessor :rate_limit
75
69
 
@@ -91,11 +85,8 @@ module PulpContainerClient
91
85
  :'url' => :'url',
92
86
  :'ca_cert' => :'ca_cert',
93
87
  :'client_cert' => :'client_cert',
94
- :'client_key' => :'client_key',
95
88
  :'tls_validation' => :'tls_validation',
96
89
  :'proxy_url' => :'proxy_url',
97
- :'username' => :'username',
98
- :'password' => :'password',
99
90
  :'pulp_labels' => :'pulp_labels',
100
91
  :'pulp_last_updated' => :'pulp_last_updated',
101
92
  :'download_concurrency' => :'download_concurrency',
@@ -104,6 +95,7 @@ module PulpContainerClient
104
95
  :'connect_timeout' => :'connect_timeout',
105
96
  :'sock_connect_timeout' => :'sock_connect_timeout',
106
97
  :'sock_read_timeout' => :'sock_read_timeout',
98
+ :'headers' => :'headers',
107
99
  :'rate_limit' => :'rate_limit',
108
100
  :'upstream_name' => :'upstream_name',
109
101
  :'include_tags' => :'include_tags',
@@ -120,11 +112,8 @@ module PulpContainerClient
120
112
  :'url' => :'String',
121
113
  :'ca_cert' => :'String',
122
114
  :'client_cert' => :'String',
123
- :'client_key' => :'String',
124
115
  :'tls_validation' => :'Boolean',
125
116
  :'proxy_url' => :'String',
126
- :'username' => :'String',
127
- :'password' => :'String',
128
117
  :'pulp_labels' => :'Object',
129
118
  :'pulp_last_updated' => :'DateTime',
130
119
  :'download_concurrency' => :'Integer',
@@ -133,6 +122,7 @@ module PulpContainerClient
133
122
  :'connect_timeout' => :'Float',
134
123
  :'sock_connect_timeout' => :'Float',
135
124
  :'sock_read_timeout' => :'Float',
125
+ :'headers' => :'Array<Object>',
136
126
  :'rate_limit' => :'Integer',
137
127
  :'upstream_name' => :'String',
138
128
  :'include_tags' => :'Array<String>',
@@ -145,10 +135,7 @@ module PulpContainerClient
145
135
  Set.new([
146
136
  :'ca_cert',
147
137
  :'client_cert',
148
- :'client_key',
149
138
  :'proxy_url',
150
- :'username',
151
- :'password',
152
139
  :'total_timeout',
153
140
  :'connect_timeout',
154
141
  :'sock_connect_timeout',
@@ -198,10 +185,6 @@ module PulpContainerClient
198
185
  self.client_cert = attributes[:'client_cert']
199
186
  end
200
187
 
201
- if attributes.key?(:'client_key')
202
- self.client_key = attributes[:'client_key']
203
- end
204
-
205
188
  if attributes.key?(:'tls_validation')
206
189
  self.tls_validation = attributes[:'tls_validation']
207
190
  end
@@ -210,14 +193,6 @@ module PulpContainerClient
210
193
  self.proxy_url = attributes[:'proxy_url']
211
194
  end
212
195
 
213
- if attributes.key?(:'username')
214
- self.username = attributes[:'username']
215
- end
216
-
217
- if attributes.key?(:'password')
218
- self.password = attributes[:'password']
219
- end
220
-
221
196
  if attributes.key?(:'pulp_labels')
222
197
  self.pulp_labels = attributes[:'pulp_labels']
223
198
  end
@@ -250,6 +225,12 @@ module PulpContainerClient
250
225
  self.sock_read_timeout = attributes[:'sock_read_timeout']
251
226
  end
252
227
 
228
+ if attributes.key?(:'headers')
229
+ if (value = attributes[:'headers']).is_a?(Array)
230
+ self.headers = value
231
+ end
232
+ end
233
+
253
234
  if attributes.key?(:'rate_limit')
254
235
  self.rate_limit = attributes[:'rate_limit']
255
236
  end
@@ -385,11 +366,8 @@ module PulpContainerClient
385
366
  url == o.url &&
386
367
  ca_cert == o.ca_cert &&
387
368
  client_cert == o.client_cert &&
388
- client_key == o.client_key &&
389
369
  tls_validation == o.tls_validation &&
390
370
  proxy_url == o.proxy_url &&
391
- username == o.username &&
392
- password == o.password &&
393
371
  pulp_labels == o.pulp_labels &&
394
372
  pulp_last_updated == o.pulp_last_updated &&
395
373
  download_concurrency == o.download_concurrency &&
@@ -398,6 +376,7 @@ module PulpContainerClient
398
376
  connect_timeout == o.connect_timeout &&
399
377
  sock_connect_timeout == o.sock_connect_timeout &&
400
378
  sock_read_timeout == o.sock_read_timeout &&
379
+ headers == o.headers &&
401
380
  rate_limit == o.rate_limit &&
402
381
  upstream_name == o.upstream_name &&
403
382
  include_tags == o.include_tags &&
@@ -413,7 +392,7 @@ module PulpContainerClient
413
392
  # Calculates hash code according to all attributes.
414
393
  # @return [Integer] Hash code
415
394
  def hash
416
- [pulp_href, pulp_created, name, url, ca_cert, client_cert, client_key, tls_validation, proxy_url, username, password, pulp_labels, pulp_last_updated, download_concurrency, policy, total_timeout, connect_timeout, sock_connect_timeout, sock_read_timeout, rate_limit, upstream_name, include_tags, exclude_tags].hash
395
+ [pulp_href, pulp_created, name, url, ca_cert, client_cert, tls_validation, proxy_url, pulp_labels, pulp_last_updated, download_concurrency, policy, total_timeout, connect_timeout, sock_connect_timeout, sock_read_timeout, headers, rate_limit, upstream_name, include_tags, exclude_tags].hash
417
396
  end
418
397
 
419
398
  # Builds the object from hash
@@ -27,28 +27,6 @@ module PulpContainerClient
27
27
  # A list of media_types to copy.
28
28
  attr_accessor :media_types
29
29
 
30
- class EnumAttributeValidator
31
- attr_reader :datatype
32
- attr_reader :allowable_values
33
-
34
- def initialize(datatype, allowable_values)
35
- @allowable_values = allowable_values.map do |value|
36
- case datatype.to_s
37
- when /Integer/i
38
- value.to_i
39
- when /Float/i
40
- value.to_f
41
- else
42
- value
43
- end
44
- end
45
- end
46
-
47
- def valid?(value)
48
- !value || allowable_values.include?(value)
49
- end
50
- end
51
-
52
30
  # Attribute mapping from ruby-style variable name to JSON key.
53
31
  def self.attribute_map
54
32
  {
@@ -65,7 +43,7 @@ module PulpContainerClient
65
43
  :'source_repository' => :'String',
66
44
  :'source_repository_version' => :'String',
67
45
  :'digests' => :'Array<Object>',
68
- :'media_types' => :'Array<String>'
46
+ :'media_types' => :'Array<MediaTypesEnum>'
69
47
  }
70
48
  end
71
49
 
@@ -0,0 +1,39 @@
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.2.3
10
+
11
+ =end
12
+
13
+ require 'date'
14
+
15
+ module PulpContainerClient
16
+ class MediaTypesEnum
17
+ DOCKER_DISTRIBUTION_MANIFEST_V1JSON = "application/vnd.docker.distribution.manifest.v1+json".freeze
18
+ DOCKER_DISTRIBUTION_MANIFEST_V2JSON = "application/vnd.docker.distribution.manifest.v2+json".freeze
19
+ DOCKER_DISTRIBUTION_MANIFEST_LIST_V2JSON = "application/vnd.docker.distribution.manifest.list.v2+json".freeze
20
+ OCI_IMAGE_MANIFEST_V1JSON = "application/vnd.oci.image.manifest.v1+json".freeze
21
+ OCI_IMAGE_INDEX_V1JSON = "application/vnd.oci.image.index.v1+json".freeze
22
+
23
+ # Builds the enum from string
24
+ # @param [String] The enum value in the form of the string
25
+ # @return [String] The enum value
26
+ def self.build_from_hash(value)
27
+ new.build_from_hash(value)
28
+ end
29
+
30
+ # Builds the enum from string
31
+ # @param [String] The enum value in the form of the string
32
+ # @return [String] The enum value
33
+ def build_from_hash(value)
34
+ constantValues = MediaTypesEnum.constants.select { |c| MediaTypesEnum::const_get(c) == value }
35
+ raise "Invalid ENUM value #{value} for class #MediaTypesEnum" if constantValues.empty?
36
+ value
37
+ end
38
+ end
39
+ end
@@ -15,23 +15,23 @@ require 'date'
15
15
  module PulpContainerClient
16
16
  # A serializer for ContainerDistribution.
17
17
  class PatchedcontainerContainerDistribution
18
+ attr_accessor :pulp_labels
19
+
20
+ # The base (relative) path component of the published url. Avoid paths that overlap with other distribution base paths (e.g. \"foo\" and \"foo/bar\")
21
+ attr_accessor :base_path
22
+
23
+ # RepositoryVersion to be served
24
+ attr_accessor :repository_version
25
+
18
26
  # A unique name. Ex, `rawhide` and `stable`.
19
27
  attr_accessor :name
20
28
 
21
- attr_accessor :pulp_labels
22
-
23
29
  # The latest RepositoryVersion for this Repository will be served.
24
30
  attr_accessor :repository
25
31
 
26
- # The base (relative) path component of the published url. Avoid paths that overlap with other distribution base paths (e.g. \"foo\" and \"foo/bar\")
27
- attr_accessor :base_path
28
-
29
32
  # An optional content-guard. If none is specified, a default one will be used.
30
33
  attr_accessor :content_guard
31
34
 
32
- # RepositoryVersion to be served
33
- attr_accessor :repository_version
34
-
35
35
  # Restrict pull access to explicitly authorized users. Defaults to unrestricted pull access.
36
36
  attr_accessor :private
37
37
 
@@ -41,12 +41,12 @@ module PulpContainerClient
41
41
  # Attribute mapping from ruby-style variable name to JSON key.
42
42
  def self.attribute_map
43
43
  {
44
- :'name' => :'name',
45
44
  :'pulp_labels' => :'pulp_labels',
46
- :'repository' => :'repository',
47
45
  :'base_path' => :'base_path',
48
- :'content_guard' => :'content_guard',
49
46
  :'repository_version' => :'repository_version',
47
+ :'name' => :'name',
48
+ :'repository' => :'repository',
49
+ :'content_guard' => :'content_guard',
50
50
  :'private' => :'private',
51
51
  :'description' => :'description'
52
52
  }
@@ -55,12 +55,12 @@ module PulpContainerClient
55
55
  # Attribute type mapping.
56
56
  def self.openapi_types
57
57
  {
58
- :'name' => :'String',
59
58
  :'pulp_labels' => :'Object',
60
- :'repository' => :'String',
61
59
  :'base_path' => :'String',
62
- :'content_guard' => :'String',
63
60
  :'repository_version' => :'String',
61
+ :'name' => :'String',
62
+ :'repository' => :'String',
63
+ :'content_guard' => :'String',
64
64
  :'private' => :'Boolean',
65
65
  :'description' => :'String'
66
66
  }
@@ -69,8 +69,8 @@ module PulpContainerClient
69
69
  # List of attributes with nullable: true
70
70
  def self.openapi_nullable
71
71
  Set.new([
72
- :'repository',
73
72
  :'repository_version',
73
+ :'repository',
74
74
  :'description'
75
75
  ])
76
76
  end
@@ -90,30 +90,30 @@ module PulpContainerClient
90
90
  h[k.to_sym] = v
91
91
  }
92
92
 
93
- if attributes.key?(:'name')
94
- self.name = attributes[:'name']
95
- end
96
-
97
93
  if attributes.key?(:'pulp_labels')
98
94
  self.pulp_labels = attributes[:'pulp_labels']
99
95
  end
100
96
 
101
- if attributes.key?(:'repository')
102
- self.repository = attributes[:'repository']
103
- end
104
-
105
97
  if attributes.key?(:'base_path')
106
98
  self.base_path = attributes[:'base_path']
107
99
  end
108
100
 
109
- if attributes.key?(:'content_guard')
110
- self.content_guard = attributes[:'content_guard']
111
- end
112
-
113
101
  if attributes.key?(:'repository_version')
114
102
  self.repository_version = attributes[:'repository_version']
115
103
  end
116
104
 
105
+ if attributes.key?(:'name')
106
+ self.name = attributes[:'name']
107
+ end
108
+
109
+ if attributes.key?(:'repository')
110
+ self.repository = attributes[:'repository']
111
+ end
112
+
113
+ if attributes.key?(:'content_guard')
114
+ self.content_guard = attributes[:'content_guard']
115
+ end
116
+
117
117
  if attributes.key?(:'private')
118
118
  self.private = attributes[:'private']
119
119
  end
@@ -141,12 +141,12 @@ module PulpContainerClient
141
141
  def ==(o)
142
142
  return true if self.equal?(o)
143
143
  self.class == o.class &&
144
- name == o.name &&
145
144
  pulp_labels == o.pulp_labels &&
146
- repository == o.repository &&
147
145
  base_path == o.base_path &&
148
- content_guard == o.content_guard &&
149
146
  repository_version == o.repository_version &&
147
+ name == o.name &&
148
+ repository == o.repository &&
149
+ content_guard == o.content_guard &&
150
150
  private == o.private &&
151
151
  description == o.description
152
152
  end
@@ -160,7 +160,7 @@ module PulpContainerClient
160
160
  # Calculates hash code according to all attributes.
161
161
  # @return [Integer] Hash code
162
162
  def hash
163
- [name, pulp_labels, repository, base_path, content_guard, repository_version, private, description].hash
163
+ [pulp_labels, base_path, repository_version, name, repository, content_guard, private, description].hash
164
164
  end
165
165
 
166
166
  # Builds the object from hash