pulp_ostree_client 2.2.1 → 2.3.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +23 -4
- data/docs/ContentCommitsApi.md +2 -0
- data/docs/ContentConfigsApi.md +2 -0
- data/docs/ContentContentApi.md +56 -0
- data/docs/ContentObjectsApi.md +2 -0
- data/docs/ContentRefsApi.md +2 -0
- data/docs/ContentSummariesApi.md +2 -0
- data/docs/DistributionsOstreeApi.md +232 -0
- data/docs/MyPermissionsResponse.md +17 -0
- data/docs/NestedRole.md +21 -0
- data/docs/NestedRoleResponse.md +21 -0
- data/docs/ObjectRolesResponse.md +17 -0
- data/docs/OstreeOstreeCommitResponse.md +2 -0
- data/docs/OstreeOstreeConfigResponse.md +2 -0
- data/docs/OstreeOstreeContent.md +23 -0
- data/docs/OstreeOstreeContentResponse.md +2 -0
- data/docs/OstreeOstreeDistributionResponse.md +2 -0
- data/docs/OstreeOstreeObjectResponse.md +2 -0
- data/docs/OstreeOstreeRefResponse.md +2 -0
- data/docs/OstreeOstreeRemoteResponse.md +2 -2
- data/docs/OstreeOstreeRemoteResponseHiddenFields.md +2 -2
- data/docs/OstreeOstreeRepositoryResponse.md +2 -0
- data/docs/OstreeOstreeSummaryResponse.md +2 -0
- data/docs/PaginatedRepositoryVersionResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeCommitResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeConfigResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeContentResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeDistributionResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeObjectResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeRefResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeRemoteResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeRepositoryResponseList.md +2 -2
- data/docs/PaginatedostreeOstreeSummaryResponseList.md +2 -2
- data/docs/RemotesOstreeApi.md +232 -0
- data/docs/RepositoriesOstreeApi.md +232 -0
- data/docs/RepositoryVersionResponse.md +2 -0
- data/lib/pulp_ostree_client/api/content_commits_api.rb +3 -0
- data/lib/pulp_ostree_client/api/content_configs_api.rb +3 -0
- data/lib/pulp_ostree_client/api/content_content_api.rb +67 -0
- data/lib/pulp_ostree_client/api/content_objects_api.rb +3 -0
- data/lib/pulp_ostree_client/api/content_refs_api.rb +3 -0
- data/lib/pulp_ostree_client/api/content_summaries_api.rb +3 -0
- data/lib/pulp_ostree_client/api/distributions_ostree_api.rb +276 -0
- data/lib/pulp_ostree_client/api/remotes_ostree_api.rb +276 -0
- data/lib/pulp_ostree_client/api/repositories_ostree_api.rb +276 -0
- data/lib/pulp_ostree_client/models/my_permissions_response.rb +213 -0
- data/lib/pulp_ostree_client/models/nested_role.rb +253 -0
- data/lib/pulp_ostree_client/models/nested_role_response.rb +234 -0
- data/lib/pulp_ostree_client/models/object_roles_response.rb +213 -0
- data/lib/pulp_ostree_client/models/ostree_ostree_commit_response.rb +11 -1
- data/lib/pulp_ostree_client/models/ostree_ostree_config_response.rb +11 -1
- data/lib/pulp_ostree_client/models/ostree_ostree_content.rb +289 -0
- data/lib/pulp_ostree_client/models/ostree_ostree_content_response.rb +11 -1
- data/lib/pulp_ostree_client/models/ostree_ostree_distribution_response.rb +11 -1
- data/lib/pulp_ostree_client/models/ostree_ostree_object_response.rb +11 -1
- data/lib/pulp_ostree_client/models/ostree_ostree_ref_response.rb +11 -1
- data/lib/pulp_ostree_client/models/ostree_ostree_remote_response.rb +11 -11
- data/lib/pulp_ostree_client/models/ostree_ostree_remote_response_hidden_fields.rb +10 -0
- data/lib/pulp_ostree_client/models/ostree_ostree_repository_response.rb +11 -1
- data/lib/pulp_ostree_client/models/ostree_ostree_summary_response.rb +11 -1
- data/lib/pulp_ostree_client/models/paginated_repository_version_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_commit_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_config_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_content_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_distribution_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_object_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_ref_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_remote_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_repository_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/paginatedostree_ostree_summary_response_list.rb +10 -0
- data/lib/pulp_ostree_client/models/repository_version_response.rb +11 -1
- data/lib/pulp_ostree_client/version.rb +1 -1
- data/lib/pulp_ostree_client.rb +5 -0
- data/spec/api/content_commits_api_spec.rb +1 -0
- data/spec/api/content_configs_api_spec.rb +1 -0
- data/spec/api/content_content_api_spec.rb +13 -0
- data/spec/api/content_objects_api_spec.rb +1 -0
- data/spec/api/content_refs_api_spec.rb +1 -0
- data/spec/api/content_summaries_api_spec.rb +1 -0
- data/spec/api/distributions_ostree_api_spec.rb +54 -0
- data/spec/api/remotes_ostree_api_spec.rb +54 -0
- data/spec/api/repositories_ostree_api_spec.rb +54 -0
- data/spec/models/my_permissions_response_spec.rb +41 -0
- data/spec/models/nested_role_response_spec.rb +53 -0
- data/spec/models/nested_role_spec.rb +53 -0
- data/spec/models/object_roles_response_spec.rb +41 -0
- data/spec/models/ostree_ostree_commit_response_spec.rb +6 -0
- data/spec/models/ostree_ostree_config_response_spec.rb +6 -0
- data/spec/models/ostree_ostree_content_response_spec.rb +6 -0
- data/spec/models/ostree_ostree_content_spec.rb +59 -0
- data/spec/models/ostree_ostree_distribution_response_spec.rb +6 -0
- data/spec/models/ostree_ostree_object_response_spec.rb +6 -0
- data/spec/models/ostree_ostree_ref_response_spec.rb +6 -0
- data/spec/models/ostree_ostree_remote_response_spec.rb +6 -6
- data/spec/models/ostree_ostree_repository_response_spec.rb +6 -0
- data/spec/models/ostree_ostree_summary_response_spec.rb +6 -0
- data/spec/models/repository_version_response_spec.rb +6 -0
- metadata +55 -35
@@ -19,6 +19,76 @@ module PulpOstreeClient
|
|
19
19
|
def initialize(api_client = ApiClient.default)
|
20
20
|
@api_client = api_client
|
21
21
|
end
|
22
|
+
# Add a role
|
23
|
+
# Add a role for this object to users/groups.
|
24
|
+
# @param ostree_ostree_distribution_href [String]
|
25
|
+
# @param nested_role [NestedRole]
|
26
|
+
# @param [Hash] opts the optional parameters
|
27
|
+
# @return [NestedRoleResponse]
|
28
|
+
def add_role(ostree_ostree_distribution_href, nested_role, opts = {})
|
29
|
+
data, _status_code, _headers = add_role_with_http_info(ostree_ostree_distribution_href, nested_role, opts)
|
30
|
+
data
|
31
|
+
end
|
32
|
+
|
33
|
+
# Add a role
|
34
|
+
# Add a role for this object to users/groups.
|
35
|
+
# @param ostree_ostree_distribution_href [String]
|
36
|
+
# @param nested_role [NestedRole]
|
37
|
+
# @param [Hash] opts the optional parameters
|
38
|
+
# @return [Array<(NestedRoleResponse, Integer, Hash)>] NestedRoleResponse data, response status code and response headers
|
39
|
+
def add_role_with_http_info(ostree_ostree_distribution_href, nested_role, opts = {})
|
40
|
+
if @api_client.config.debugging
|
41
|
+
@api_client.config.logger.debug 'Calling API: DistributionsOstreeApi.add_role ...'
|
42
|
+
end
|
43
|
+
# verify the required parameter 'ostree_ostree_distribution_href' is set
|
44
|
+
if @api_client.config.client_side_validation && ostree_ostree_distribution_href.nil?
|
45
|
+
fail ArgumentError, "Missing the required parameter 'ostree_ostree_distribution_href' when calling DistributionsOstreeApi.add_role"
|
46
|
+
end
|
47
|
+
# verify the required parameter 'nested_role' is set
|
48
|
+
if @api_client.config.client_side_validation && nested_role.nil?
|
49
|
+
fail ArgumentError, "Missing the required parameter 'nested_role' when calling DistributionsOstreeApi.add_role"
|
50
|
+
end
|
51
|
+
# resource path
|
52
|
+
local_var_path = '{ostree_ostree_distribution_href}add_role/'.sub('{' + 'ostree_ostree_distribution_href' + '}', CGI.escape(ostree_ostree_distribution_href.to_s).gsub('%2F', '/'))
|
53
|
+
|
54
|
+
# query parameters
|
55
|
+
query_params = opts[:query_params] || {}
|
56
|
+
|
57
|
+
# header parameters
|
58
|
+
header_params = opts[:header_params] || {}
|
59
|
+
# HTTP header 'Accept' (if needed)
|
60
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
61
|
+
# HTTP header 'Content-Type'
|
62
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'application/x-www-form-urlencoded', 'multipart/form-data'])
|
63
|
+
|
64
|
+
# form parameters
|
65
|
+
form_params = opts[:form_params] || {}
|
66
|
+
|
67
|
+
# http body (model)
|
68
|
+
post_body = opts[:body] || @api_client.object_to_http_body(nested_role)
|
69
|
+
|
70
|
+
# return_type
|
71
|
+
return_type = opts[:return_type] || 'NestedRoleResponse'
|
72
|
+
|
73
|
+
# auth_names
|
74
|
+
auth_names = opts[:auth_names] || ['basicAuth']
|
75
|
+
|
76
|
+
new_options = opts.merge(
|
77
|
+
:header_params => header_params,
|
78
|
+
:query_params => query_params,
|
79
|
+
:form_params => form_params,
|
80
|
+
:body => post_body,
|
81
|
+
:auth_names => auth_names,
|
82
|
+
:return_type => return_type
|
83
|
+
)
|
84
|
+
|
85
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
86
|
+
if @api_client.config.debugging
|
87
|
+
@api_client.config.logger.debug "API called: DistributionsOstreeApi#add_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
88
|
+
end
|
89
|
+
return data, status_code, headers
|
90
|
+
end
|
91
|
+
|
22
92
|
# Create an ostree distribution
|
23
93
|
# Trigger an asynchronous create task
|
24
94
|
# @param ostree_ostree_distribution [OstreeOstreeDistribution]
|
@@ -280,6 +350,142 @@ module PulpOstreeClient
|
|
280
350
|
return data, status_code, headers
|
281
351
|
end
|
282
352
|
|
353
|
+
# List roles
|
354
|
+
# List roles assigned to this object.
|
355
|
+
# @param ostree_ostree_distribution_href [String]
|
356
|
+
# @param [Hash] opts the optional parameters
|
357
|
+
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
358
|
+
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
359
|
+
# @return [ObjectRolesResponse]
|
360
|
+
def list_roles(ostree_ostree_distribution_href, opts = {})
|
361
|
+
data, _status_code, _headers = list_roles_with_http_info(ostree_ostree_distribution_href, opts)
|
362
|
+
data
|
363
|
+
end
|
364
|
+
|
365
|
+
# List roles
|
366
|
+
# List roles assigned to this object.
|
367
|
+
# @param ostree_ostree_distribution_href [String]
|
368
|
+
# @param [Hash] opts the optional parameters
|
369
|
+
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
370
|
+
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
371
|
+
# @return [Array<(ObjectRolesResponse, Integer, Hash)>] ObjectRolesResponse data, response status code and response headers
|
372
|
+
def list_roles_with_http_info(ostree_ostree_distribution_href, opts = {})
|
373
|
+
if @api_client.config.debugging
|
374
|
+
@api_client.config.logger.debug 'Calling API: DistributionsOstreeApi.list_roles ...'
|
375
|
+
end
|
376
|
+
# verify the required parameter 'ostree_ostree_distribution_href' is set
|
377
|
+
if @api_client.config.client_side_validation && ostree_ostree_distribution_href.nil?
|
378
|
+
fail ArgumentError, "Missing the required parameter 'ostree_ostree_distribution_href' when calling DistributionsOstreeApi.list_roles"
|
379
|
+
end
|
380
|
+
# resource path
|
381
|
+
local_var_path = '{ostree_ostree_distribution_href}list_roles/'.sub('{' + 'ostree_ostree_distribution_href' + '}', CGI.escape(ostree_ostree_distribution_href.to_s).gsub('%2F', '/'))
|
382
|
+
|
383
|
+
# query parameters
|
384
|
+
query_params = opts[:query_params] || {}
|
385
|
+
query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
|
386
|
+
query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :multi) if !opts[:'exclude_fields'].nil?
|
387
|
+
|
388
|
+
# header parameters
|
389
|
+
header_params = opts[:header_params] || {}
|
390
|
+
# HTTP header 'Accept' (if needed)
|
391
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
392
|
+
|
393
|
+
# form parameters
|
394
|
+
form_params = opts[:form_params] || {}
|
395
|
+
|
396
|
+
# http body (model)
|
397
|
+
post_body = opts[:body]
|
398
|
+
|
399
|
+
# return_type
|
400
|
+
return_type = opts[:return_type] || 'ObjectRolesResponse'
|
401
|
+
|
402
|
+
# auth_names
|
403
|
+
auth_names = opts[:auth_names] || ['basicAuth']
|
404
|
+
|
405
|
+
new_options = opts.merge(
|
406
|
+
:header_params => header_params,
|
407
|
+
:query_params => query_params,
|
408
|
+
:form_params => form_params,
|
409
|
+
:body => post_body,
|
410
|
+
:auth_names => auth_names,
|
411
|
+
:return_type => return_type
|
412
|
+
)
|
413
|
+
|
414
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
415
|
+
if @api_client.config.debugging
|
416
|
+
@api_client.config.logger.debug "API called: DistributionsOstreeApi#list_roles\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
417
|
+
end
|
418
|
+
return data, status_code, headers
|
419
|
+
end
|
420
|
+
|
421
|
+
# List user permissions
|
422
|
+
# List permissions available to the current user on this object.
|
423
|
+
# @param ostree_ostree_distribution_href [String]
|
424
|
+
# @param [Hash] opts the optional parameters
|
425
|
+
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
426
|
+
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
427
|
+
# @return [MyPermissionsResponse]
|
428
|
+
def my_permissions(ostree_ostree_distribution_href, opts = {})
|
429
|
+
data, _status_code, _headers = my_permissions_with_http_info(ostree_ostree_distribution_href, opts)
|
430
|
+
data
|
431
|
+
end
|
432
|
+
|
433
|
+
# List user permissions
|
434
|
+
# List permissions available to the current user on this object.
|
435
|
+
# @param ostree_ostree_distribution_href [String]
|
436
|
+
# @param [Hash] opts the optional parameters
|
437
|
+
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
438
|
+
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
439
|
+
# @return [Array<(MyPermissionsResponse, Integer, Hash)>] MyPermissionsResponse data, response status code and response headers
|
440
|
+
def my_permissions_with_http_info(ostree_ostree_distribution_href, opts = {})
|
441
|
+
if @api_client.config.debugging
|
442
|
+
@api_client.config.logger.debug 'Calling API: DistributionsOstreeApi.my_permissions ...'
|
443
|
+
end
|
444
|
+
# verify the required parameter 'ostree_ostree_distribution_href' is set
|
445
|
+
if @api_client.config.client_side_validation && ostree_ostree_distribution_href.nil?
|
446
|
+
fail ArgumentError, "Missing the required parameter 'ostree_ostree_distribution_href' when calling DistributionsOstreeApi.my_permissions"
|
447
|
+
end
|
448
|
+
# resource path
|
449
|
+
local_var_path = '{ostree_ostree_distribution_href}my_permissions/'.sub('{' + 'ostree_ostree_distribution_href' + '}', CGI.escape(ostree_ostree_distribution_href.to_s).gsub('%2F', '/'))
|
450
|
+
|
451
|
+
# query parameters
|
452
|
+
query_params = opts[:query_params] || {}
|
453
|
+
query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
|
454
|
+
query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :multi) if !opts[:'exclude_fields'].nil?
|
455
|
+
|
456
|
+
# header parameters
|
457
|
+
header_params = opts[:header_params] || {}
|
458
|
+
# HTTP header 'Accept' (if needed)
|
459
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
460
|
+
|
461
|
+
# form parameters
|
462
|
+
form_params = opts[:form_params] || {}
|
463
|
+
|
464
|
+
# http body (model)
|
465
|
+
post_body = opts[:body]
|
466
|
+
|
467
|
+
# return_type
|
468
|
+
return_type = opts[:return_type] || 'MyPermissionsResponse'
|
469
|
+
|
470
|
+
# auth_names
|
471
|
+
auth_names = opts[:auth_names] || ['basicAuth']
|
472
|
+
|
473
|
+
new_options = opts.merge(
|
474
|
+
:header_params => header_params,
|
475
|
+
:query_params => query_params,
|
476
|
+
:form_params => form_params,
|
477
|
+
:body => post_body,
|
478
|
+
:auth_names => auth_names,
|
479
|
+
:return_type => return_type
|
480
|
+
)
|
481
|
+
|
482
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
483
|
+
if @api_client.config.debugging
|
484
|
+
@api_client.config.logger.debug "API called: DistributionsOstreeApi#my_permissions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
485
|
+
end
|
486
|
+
return data, status_code, headers
|
487
|
+
end
|
488
|
+
|
283
489
|
# Update an ostree distribution
|
284
490
|
# Trigger an asynchronous partial update task
|
285
491
|
# @param ostree_ostree_distribution_href [String]
|
@@ -418,6 +624,76 @@ module PulpOstreeClient
|
|
418
624
|
return data, status_code, headers
|
419
625
|
end
|
420
626
|
|
627
|
+
# Remove a role
|
628
|
+
# Remove a role for this object from users/groups.
|
629
|
+
# @param ostree_ostree_distribution_href [String]
|
630
|
+
# @param nested_role [NestedRole]
|
631
|
+
# @param [Hash] opts the optional parameters
|
632
|
+
# @return [NestedRoleResponse]
|
633
|
+
def remove_role(ostree_ostree_distribution_href, nested_role, opts = {})
|
634
|
+
data, _status_code, _headers = remove_role_with_http_info(ostree_ostree_distribution_href, nested_role, opts)
|
635
|
+
data
|
636
|
+
end
|
637
|
+
|
638
|
+
# Remove a role
|
639
|
+
# Remove a role for this object from users/groups.
|
640
|
+
# @param ostree_ostree_distribution_href [String]
|
641
|
+
# @param nested_role [NestedRole]
|
642
|
+
# @param [Hash] opts the optional parameters
|
643
|
+
# @return [Array<(NestedRoleResponse, Integer, Hash)>] NestedRoleResponse data, response status code and response headers
|
644
|
+
def remove_role_with_http_info(ostree_ostree_distribution_href, nested_role, opts = {})
|
645
|
+
if @api_client.config.debugging
|
646
|
+
@api_client.config.logger.debug 'Calling API: DistributionsOstreeApi.remove_role ...'
|
647
|
+
end
|
648
|
+
# verify the required parameter 'ostree_ostree_distribution_href' is set
|
649
|
+
if @api_client.config.client_side_validation && ostree_ostree_distribution_href.nil?
|
650
|
+
fail ArgumentError, "Missing the required parameter 'ostree_ostree_distribution_href' when calling DistributionsOstreeApi.remove_role"
|
651
|
+
end
|
652
|
+
# verify the required parameter 'nested_role' is set
|
653
|
+
if @api_client.config.client_side_validation && nested_role.nil?
|
654
|
+
fail ArgumentError, "Missing the required parameter 'nested_role' when calling DistributionsOstreeApi.remove_role"
|
655
|
+
end
|
656
|
+
# resource path
|
657
|
+
local_var_path = '{ostree_ostree_distribution_href}remove_role/'.sub('{' + 'ostree_ostree_distribution_href' + '}', CGI.escape(ostree_ostree_distribution_href.to_s).gsub('%2F', '/'))
|
658
|
+
|
659
|
+
# query parameters
|
660
|
+
query_params = opts[:query_params] || {}
|
661
|
+
|
662
|
+
# header parameters
|
663
|
+
header_params = opts[:header_params] || {}
|
664
|
+
# HTTP header 'Accept' (if needed)
|
665
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
666
|
+
# HTTP header 'Content-Type'
|
667
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'application/x-www-form-urlencoded', 'multipart/form-data'])
|
668
|
+
|
669
|
+
# form parameters
|
670
|
+
form_params = opts[:form_params] || {}
|
671
|
+
|
672
|
+
# http body (model)
|
673
|
+
post_body = opts[:body] || @api_client.object_to_http_body(nested_role)
|
674
|
+
|
675
|
+
# return_type
|
676
|
+
return_type = opts[:return_type] || 'NestedRoleResponse'
|
677
|
+
|
678
|
+
# auth_names
|
679
|
+
auth_names = opts[:auth_names] || ['basicAuth']
|
680
|
+
|
681
|
+
new_options = opts.merge(
|
682
|
+
:header_params => header_params,
|
683
|
+
:query_params => query_params,
|
684
|
+
:form_params => form_params,
|
685
|
+
:body => post_body,
|
686
|
+
:auth_names => auth_names,
|
687
|
+
:return_type => return_type
|
688
|
+
)
|
689
|
+
|
690
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
691
|
+
if @api_client.config.debugging
|
692
|
+
@api_client.config.logger.debug "API called: DistributionsOstreeApi#remove_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
693
|
+
end
|
694
|
+
return data, status_code, headers
|
695
|
+
end
|
696
|
+
|
421
697
|
# Set a label
|
422
698
|
# Set a single pulp_label on the object to a specific value or null.
|
423
699
|
# @param ostree_ostree_distribution_href [String]
|
@@ -19,6 +19,76 @@ module PulpOstreeClient
|
|
19
19
|
def initialize(api_client = ApiClient.default)
|
20
20
|
@api_client = api_client
|
21
21
|
end
|
22
|
+
# Add a role
|
23
|
+
# Add a role for this object to users/groups.
|
24
|
+
# @param ostree_ostree_remote_href [String]
|
25
|
+
# @param nested_role [NestedRole]
|
26
|
+
# @param [Hash] opts the optional parameters
|
27
|
+
# @return [NestedRoleResponse]
|
28
|
+
def add_role(ostree_ostree_remote_href, nested_role, opts = {})
|
29
|
+
data, _status_code, _headers = add_role_with_http_info(ostree_ostree_remote_href, nested_role, opts)
|
30
|
+
data
|
31
|
+
end
|
32
|
+
|
33
|
+
# Add a role
|
34
|
+
# Add a role for this object to users/groups.
|
35
|
+
# @param ostree_ostree_remote_href [String]
|
36
|
+
# @param nested_role [NestedRole]
|
37
|
+
# @param [Hash] opts the optional parameters
|
38
|
+
# @return [Array<(NestedRoleResponse, Integer, Hash)>] NestedRoleResponse data, response status code and response headers
|
39
|
+
def add_role_with_http_info(ostree_ostree_remote_href, nested_role, opts = {})
|
40
|
+
if @api_client.config.debugging
|
41
|
+
@api_client.config.logger.debug 'Calling API: RemotesOstreeApi.add_role ...'
|
42
|
+
end
|
43
|
+
# verify the required parameter 'ostree_ostree_remote_href' is set
|
44
|
+
if @api_client.config.client_side_validation && ostree_ostree_remote_href.nil?
|
45
|
+
fail ArgumentError, "Missing the required parameter 'ostree_ostree_remote_href' when calling RemotesOstreeApi.add_role"
|
46
|
+
end
|
47
|
+
# verify the required parameter 'nested_role' is set
|
48
|
+
if @api_client.config.client_side_validation && nested_role.nil?
|
49
|
+
fail ArgumentError, "Missing the required parameter 'nested_role' when calling RemotesOstreeApi.add_role"
|
50
|
+
end
|
51
|
+
# resource path
|
52
|
+
local_var_path = '{ostree_ostree_remote_href}add_role/'.sub('{' + 'ostree_ostree_remote_href' + '}', CGI.escape(ostree_ostree_remote_href.to_s).gsub('%2F', '/'))
|
53
|
+
|
54
|
+
# query parameters
|
55
|
+
query_params = opts[:query_params] || {}
|
56
|
+
|
57
|
+
# header parameters
|
58
|
+
header_params = opts[:header_params] || {}
|
59
|
+
# HTTP header 'Accept' (if needed)
|
60
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
61
|
+
# HTTP header 'Content-Type'
|
62
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'application/x-www-form-urlencoded', 'multipart/form-data'])
|
63
|
+
|
64
|
+
# form parameters
|
65
|
+
form_params = opts[:form_params] || {}
|
66
|
+
|
67
|
+
# http body (model)
|
68
|
+
post_body = opts[:body] || @api_client.object_to_http_body(nested_role)
|
69
|
+
|
70
|
+
# return_type
|
71
|
+
return_type = opts[:return_type] || 'NestedRoleResponse'
|
72
|
+
|
73
|
+
# auth_names
|
74
|
+
auth_names = opts[:auth_names] || ['basicAuth']
|
75
|
+
|
76
|
+
new_options = opts.merge(
|
77
|
+
:header_params => header_params,
|
78
|
+
:query_params => query_params,
|
79
|
+
:form_params => form_params,
|
80
|
+
:body => post_body,
|
81
|
+
:auth_names => auth_names,
|
82
|
+
:return_type => return_type
|
83
|
+
)
|
84
|
+
|
85
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
86
|
+
if @api_client.config.debugging
|
87
|
+
@api_client.config.logger.debug "API called: RemotesOstreeApi#add_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
88
|
+
end
|
89
|
+
return data, status_code, headers
|
90
|
+
end
|
91
|
+
|
22
92
|
# Create an ostree remote
|
23
93
|
# A ViewSet class for OSTree remote repositories.
|
24
94
|
# @param ostree_ostree_remote [OstreeOstreeRemote]
|
@@ -277,6 +347,142 @@ module PulpOstreeClient
|
|
277
347
|
return data, status_code, headers
|
278
348
|
end
|
279
349
|
|
350
|
+
# List roles
|
351
|
+
# List roles assigned to this object.
|
352
|
+
# @param ostree_ostree_remote_href [String]
|
353
|
+
# @param [Hash] opts the optional parameters
|
354
|
+
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
355
|
+
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
356
|
+
# @return [ObjectRolesResponse]
|
357
|
+
def list_roles(ostree_ostree_remote_href, opts = {})
|
358
|
+
data, _status_code, _headers = list_roles_with_http_info(ostree_ostree_remote_href, opts)
|
359
|
+
data
|
360
|
+
end
|
361
|
+
|
362
|
+
# List roles
|
363
|
+
# List roles assigned to this object.
|
364
|
+
# @param ostree_ostree_remote_href [String]
|
365
|
+
# @param [Hash] opts the optional parameters
|
366
|
+
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
367
|
+
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
368
|
+
# @return [Array<(ObjectRolesResponse, Integer, Hash)>] ObjectRolesResponse data, response status code and response headers
|
369
|
+
def list_roles_with_http_info(ostree_ostree_remote_href, opts = {})
|
370
|
+
if @api_client.config.debugging
|
371
|
+
@api_client.config.logger.debug 'Calling API: RemotesOstreeApi.list_roles ...'
|
372
|
+
end
|
373
|
+
# verify the required parameter 'ostree_ostree_remote_href' is set
|
374
|
+
if @api_client.config.client_side_validation && ostree_ostree_remote_href.nil?
|
375
|
+
fail ArgumentError, "Missing the required parameter 'ostree_ostree_remote_href' when calling RemotesOstreeApi.list_roles"
|
376
|
+
end
|
377
|
+
# resource path
|
378
|
+
local_var_path = '{ostree_ostree_remote_href}list_roles/'.sub('{' + 'ostree_ostree_remote_href' + '}', CGI.escape(ostree_ostree_remote_href.to_s).gsub('%2F', '/'))
|
379
|
+
|
380
|
+
# query parameters
|
381
|
+
query_params = opts[:query_params] || {}
|
382
|
+
query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
|
383
|
+
query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :multi) if !opts[:'exclude_fields'].nil?
|
384
|
+
|
385
|
+
# header parameters
|
386
|
+
header_params = opts[:header_params] || {}
|
387
|
+
# HTTP header 'Accept' (if needed)
|
388
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
389
|
+
|
390
|
+
# form parameters
|
391
|
+
form_params = opts[:form_params] || {}
|
392
|
+
|
393
|
+
# http body (model)
|
394
|
+
post_body = opts[:body]
|
395
|
+
|
396
|
+
# return_type
|
397
|
+
return_type = opts[:return_type] || 'ObjectRolesResponse'
|
398
|
+
|
399
|
+
# auth_names
|
400
|
+
auth_names = opts[:auth_names] || ['basicAuth']
|
401
|
+
|
402
|
+
new_options = opts.merge(
|
403
|
+
:header_params => header_params,
|
404
|
+
:query_params => query_params,
|
405
|
+
:form_params => form_params,
|
406
|
+
:body => post_body,
|
407
|
+
:auth_names => auth_names,
|
408
|
+
:return_type => return_type
|
409
|
+
)
|
410
|
+
|
411
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
412
|
+
if @api_client.config.debugging
|
413
|
+
@api_client.config.logger.debug "API called: RemotesOstreeApi#list_roles\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
414
|
+
end
|
415
|
+
return data, status_code, headers
|
416
|
+
end
|
417
|
+
|
418
|
+
# List user permissions
|
419
|
+
# List permissions available to the current user on this object.
|
420
|
+
# @param ostree_ostree_remote_href [String]
|
421
|
+
# @param [Hash] opts the optional parameters
|
422
|
+
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
423
|
+
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
424
|
+
# @return [MyPermissionsResponse]
|
425
|
+
def my_permissions(ostree_ostree_remote_href, opts = {})
|
426
|
+
data, _status_code, _headers = my_permissions_with_http_info(ostree_ostree_remote_href, opts)
|
427
|
+
data
|
428
|
+
end
|
429
|
+
|
430
|
+
# List user permissions
|
431
|
+
# List permissions available to the current user on this object.
|
432
|
+
# @param ostree_ostree_remote_href [String]
|
433
|
+
# @param [Hash] opts the optional parameters
|
434
|
+
# @option opts [Array<String>] :fields A list of fields to include in the response.
|
435
|
+
# @option opts [Array<String>] :exclude_fields A list of fields to exclude from the response.
|
436
|
+
# @return [Array<(MyPermissionsResponse, Integer, Hash)>] MyPermissionsResponse data, response status code and response headers
|
437
|
+
def my_permissions_with_http_info(ostree_ostree_remote_href, opts = {})
|
438
|
+
if @api_client.config.debugging
|
439
|
+
@api_client.config.logger.debug 'Calling API: RemotesOstreeApi.my_permissions ...'
|
440
|
+
end
|
441
|
+
# verify the required parameter 'ostree_ostree_remote_href' is set
|
442
|
+
if @api_client.config.client_side_validation && ostree_ostree_remote_href.nil?
|
443
|
+
fail ArgumentError, "Missing the required parameter 'ostree_ostree_remote_href' when calling RemotesOstreeApi.my_permissions"
|
444
|
+
end
|
445
|
+
# resource path
|
446
|
+
local_var_path = '{ostree_ostree_remote_href}my_permissions/'.sub('{' + 'ostree_ostree_remote_href' + '}', CGI.escape(ostree_ostree_remote_href.to_s).gsub('%2F', '/'))
|
447
|
+
|
448
|
+
# query parameters
|
449
|
+
query_params = opts[:query_params] || {}
|
450
|
+
query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :multi) if !opts[:'fields'].nil?
|
451
|
+
query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :multi) if !opts[:'exclude_fields'].nil?
|
452
|
+
|
453
|
+
# header parameters
|
454
|
+
header_params = opts[:header_params] || {}
|
455
|
+
# HTTP header 'Accept' (if needed)
|
456
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
457
|
+
|
458
|
+
# form parameters
|
459
|
+
form_params = opts[:form_params] || {}
|
460
|
+
|
461
|
+
# http body (model)
|
462
|
+
post_body = opts[:body]
|
463
|
+
|
464
|
+
# return_type
|
465
|
+
return_type = opts[:return_type] || 'MyPermissionsResponse'
|
466
|
+
|
467
|
+
# auth_names
|
468
|
+
auth_names = opts[:auth_names] || ['basicAuth']
|
469
|
+
|
470
|
+
new_options = opts.merge(
|
471
|
+
:header_params => header_params,
|
472
|
+
:query_params => query_params,
|
473
|
+
:form_params => form_params,
|
474
|
+
:body => post_body,
|
475
|
+
:auth_names => auth_names,
|
476
|
+
:return_type => return_type
|
477
|
+
)
|
478
|
+
|
479
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
480
|
+
if @api_client.config.debugging
|
481
|
+
@api_client.config.logger.debug "API called: RemotesOstreeApi#my_permissions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
482
|
+
end
|
483
|
+
return data, status_code, headers
|
484
|
+
end
|
485
|
+
|
280
486
|
# Update an ostree remote
|
281
487
|
# Trigger an asynchronous partial update task
|
282
488
|
# @param ostree_ostree_remote_href [String]
|
@@ -415,6 +621,76 @@ module PulpOstreeClient
|
|
415
621
|
return data, status_code, headers
|
416
622
|
end
|
417
623
|
|
624
|
+
# Remove a role
|
625
|
+
# Remove a role for this object from users/groups.
|
626
|
+
# @param ostree_ostree_remote_href [String]
|
627
|
+
# @param nested_role [NestedRole]
|
628
|
+
# @param [Hash] opts the optional parameters
|
629
|
+
# @return [NestedRoleResponse]
|
630
|
+
def remove_role(ostree_ostree_remote_href, nested_role, opts = {})
|
631
|
+
data, _status_code, _headers = remove_role_with_http_info(ostree_ostree_remote_href, nested_role, opts)
|
632
|
+
data
|
633
|
+
end
|
634
|
+
|
635
|
+
# Remove a role
|
636
|
+
# Remove a role for this object from users/groups.
|
637
|
+
# @param ostree_ostree_remote_href [String]
|
638
|
+
# @param nested_role [NestedRole]
|
639
|
+
# @param [Hash] opts the optional parameters
|
640
|
+
# @return [Array<(NestedRoleResponse, Integer, Hash)>] NestedRoleResponse data, response status code and response headers
|
641
|
+
def remove_role_with_http_info(ostree_ostree_remote_href, nested_role, opts = {})
|
642
|
+
if @api_client.config.debugging
|
643
|
+
@api_client.config.logger.debug 'Calling API: RemotesOstreeApi.remove_role ...'
|
644
|
+
end
|
645
|
+
# verify the required parameter 'ostree_ostree_remote_href' is set
|
646
|
+
if @api_client.config.client_side_validation && ostree_ostree_remote_href.nil?
|
647
|
+
fail ArgumentError, "Missing the required parameter 'ostree_ostree_remote_href' when calling RemotesOstreeApi.remove_role"
|
648
|
+
end
|
649
|
+
# verify the required parameter 'nested_role' is set
|
650
|
+
if @api_client.config.client_side_validation && nested_role.nil?
|
651
|
+
fail ArgumentError, "Missing the required parameter 'nested_role' when calling RemotesOstreeApi.remove_role"
|
652
|
+
end
|
653
|
+
# resource path
|
654
|
+
local_var_path = '{ostree_ostree_remote_href}remove_role/'.sub('{' + 'ostree_ostree_remote_href' + '}', CGI.escape(ostree_ostree_remote_href.to_s).gsub('%2F', '/'))
|
655
|
+
|
656
|
+
# query parameters
|
657
|
+
query_params = opts[:query_params] || {}
|
658
|
+
|
659
|
+
# header parameters
|
660
|
+
header_params = opts[:header_params] || {}
|
661
|
+
# HTTP header 'Accept' (if needed)
|
662
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
663
|
+
# HTTP header 'Content-Type'
|
664
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json', 'application/x-www-form-urlencoded', 'multipart/form-data'])
|
665
|
+
|
666
|
+
# form parameters
|
667
|
+
form_params = opts[:form_params] || {}
|
668
|
+
|
669
|
+
# http body (model)
|
670
|
+
post_body = opts[:body] || @api_client.object_to_http_body(nested_role)
|
671
|
+
|
672
|
+
# return_type
|
673
|
+
return_type = opts[:return_type] || 'NestedRoleResponse'
|
674
|
+
|
675
|
+
# auth_names
|
676
|
+
auth_names = opts[:auth_names] || ['basicAuth']
|
677
|
+
|
678
|
+
new_options = opts.merge(
|
679
|
+
:header_params => header_params,
|
680
|
+
:query_params => query_params,
|
681
|
+
:form_params => form_params,
|
682
|
+
:body => post_body,
|
683
|
+
:auth_names => auth_names,
|
684
|
+
:return_type => return_type
|
685
|
+
)
|
686
|
+
|
687
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
688
|
+
if @api_client.config.debugging
|
689
|
+
@api_client.config.logger.debug "API called: RemotesOstreeApi#remove_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
690
|
+
end
|
691
|
+
return data, status_code, headers
|
692
|
+
end
|
693
|
+
|
418
694
|
# Set a label
|
419
695
|
# Set a single pulp_label on the object to a specific value or null.
|
420
696
|
# @param ostree_ostree_remote_href [String]
|