openshift-python-wrapper 4.13.9__tar.gz → 4.13.12__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/PKG-INFO +1 -1
- openshift-python-wrapper-4.13.12/VERSION +1 -0
- openshift-python-wrapper-4.13.12/ocp_resources/cron_job.py +102 -0
- openshift-python-wrapper-4.13.12/ocp_resources/csi_storage_capacity.py +77 -0
- openshift-python-wrapper-4.13.12/ocp_resources/endpoint_slice.py +68 -0
- openshift-python-wrapper-4.13.12/ocp_resources/image_content_source_policy.py +33 -0
- openshift-python-wrapper-4.13.12/ocp_resources/lease.py +72 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/node.py +3 -6
- openshift-python-wrapper-4.13.12/ocp_resources/pipeline.py +58 -0
- openshift-python-wrapper-4.13.12/ocp_resources/pod_metrics.py +10 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/resource.py +6 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/virtual_machine_restore.py +1 -2
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/virtual_machine_snapshot.py +1 -2
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/openshift_python_wrapper.egg-info/PKG-INFO +1 -1
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/openshift_python_wrapper.egg-info/SOURCES.txt +6 -0
- openshift-python-wrapper-4.13.9/VERSION +0 -1
- openshift-python-wrapper-4.13.9/ocp_resources/image_content_source_policy.py +0 -9
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/LICENSE +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/README.md +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/__init__.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/api_server.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/api_service.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/backup.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/benchmark.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/catalog_source.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/catalog_source_config.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/cdi.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/cdi_config.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/chaos_engine.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/chaos_result.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/cluster_operator.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/cluster_role.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/cluster_role_binding.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/cluster_service_version.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/cluster_version.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/configmap.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/console_cli_download.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/console_plugin.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/console_quick_start.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/constants.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/controller_revision.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/csidriver.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/custom_resource_definition.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/daemonset.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/data_import_cron.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/data_source.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/datavolume.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/deployment.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/destination_rule.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/endpoints.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/event.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/forklift_controller.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/gateway.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/hook.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/host.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/hostpath_provisioner.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/hyperconverged.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/image.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/image_stream.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/imagestreamtag.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/infrastructure.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/installplan.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/ip_address_pool.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/job.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/kube_descheduler.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/kubevirt.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/kubevirt_common_templates_bundle.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/kubevirt_metrics_aggregation.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/kubevirt_node_labeller_bundle.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/kubevirt_template_validaotr.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/l2_advertisement.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/machine.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/machine_config.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/machine_config_pool.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/machine_health_check.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/machine_set.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/metallb.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/migration.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/migration_policy.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/mtv.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/mutating_webhook_config.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/namespace.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/network.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/network_addons_config.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/network_attachment_definition.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/network_map.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/network_policy.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/nmstate.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/node_health_check.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/node_maintenance.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/node_network_configuration_enactment.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/node_network_configuration_policy.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/node_network_state.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/oauth.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/operator.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/operator_condition.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/operator_group.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/operator_hub.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/operator_source.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/package_manifest.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/peer_authentication.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/persistent_volume.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/persistent_volume_claim.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/pipelineruns.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/plan.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/pod.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/pod_disruption_budget.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/priority_class.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/project.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/prometheus.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/prometheus_rule.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/provider.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/replicaset.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/restore.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/rhmi.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/role.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/role_binding.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/route.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/scheduler.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/secret.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/security_context_constraints.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/service.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/service_account.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/service_mesh_control_plane.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/service_mesh_member_roll.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/service_monitor.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/sriov_network.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/sriov_network_node_policy.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/sriov_network_node_state.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/ssp.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/storage_class.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/storage_map.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/storage_profile.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/subscription.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/tekton_tasks.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/template.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/upload_token_request.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/utils.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/validating_webhook_config.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/virtual_machine.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/virtual_machine_Instance_replica_set.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/virtual_machine_cluster_instance_types.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/virtual_machine_cluster_preferences.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/virtual_machine_export.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/virtual_machine_import.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/virtual_machine_instance.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/virtual_machine_instance_migration.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/virtual_machine_instance_preset.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/virtual_machine_instance_types.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/virtual_machine_preferences.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/virtual_service.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/vm_import_config.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/volume_snapshot.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/volume_snapshot_class.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/openshift_python_wrapper.egg-info/dependency_links.txt +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/openshift_python_wrapper.egg-info/requires.txt +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/openshift_python_wrapper.egg-info/top_level.txt +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/pyproject.toml +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/setup.cfg +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/tests/test_resources.py +0 -0
- {openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/tests/test_validate_resources.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: openshift-python-wrapper
|
|
3
|
-
Version: 4.13.
|
|
3
|
+
Version: 4.13.12
|
|
4
4
|
Summary: Wrapper around https://github.com/openshift/openshift-restclient-python
|
|
5
5
|
Author-email: Meni Yakove <myakove@gmail.com>, Ruth Netser <rnetser@gmail.com>
|
|
6
6
|
Project-URL: Homepage, https://github.com/RedHatQE/openshift-python-wrapper
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
4.13.12
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
from ocp_resources.constants import TIMEOUT_4MINUTES
|
|
2
|
+
from ocp_resources.resource import NamespacedResource
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
class CronJob(NamespacedResource):
|
|
6
|
+
"""
|
|
7
|
+
CronJob object. API reference:
|
|
8
|
+
https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/cron-job-v1/
|
|
9
|
+
"""
|
|
10
|
+
|
|
11
|
+
api_group = NamespacedResource.ApiGroup.BATCH
|
|
12
|
+
|
|
13
|
+
def __init__(
|
|
14
|
+
self,
|
|
15
|
+
name=None,
|
|
16
|
+
namespace=None,
|
|
17
|
+
client=None,
|
|
18
|
+
teardown=True,
|
|
19
|
+
schedule=None,
|
|
20
|
+
job_template=None,
|
|
21
|
+
timezone=None,
|
|
22
|
+
concurrency_policy=None,
|
|
23
|
+
starting_deadline_seconds=None,
|
|
24
|
+
suspend=None,
|
|
25
|
+
successful_jobs_history_limit=None,
|
|
26
|
+
failed_jobs_history_limit=None,
|
|
27
|
+
privileged_client=None,
|
|
28
|
+
yaml_file=None,
|
|
29
|
+
delete_timeout=TIMEOUT_4MINUTES,
|
|
30
|
+
**kwargs,
|
|
31
|
+
):
|
|
32
|
+
"""
|
|
33
|
+
Args:
|
|
34
|
+
name (str): Name of the CronJob resource
|
|
35
|
+
namespace (str): Namespace of CronJob resource
|
|
36
|
+
client: (DynamicClient): DynamicClient for api calls
|
|
37
|
+
teardown (bool): Indicates if the resource should be torn down at the end
|
|
38
|
+
privileged_client (DynamicClient): Privileged client for api calls
|
|
39
|
+
yaml_file (str): yaml file for the resource.
|
|
40
|
+
delete_timeout (int, optional): timeout associated with delete action
|
|
41
|
+
schedule (str): schedule of the cron job
|
|
42
|
+
job_template (dict): describes the job that would be created when a cronjob would be executed
|
|
43
|
+
Example:
|
|
44
|
+
job_template: https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/job-v1/#JobSpec
|
|
45
|
+
timezone (str, optional): timezone name for the given schedule
|
|
46
|
+
concurrency_policy (str, optional): indicates how to treat concurrent execution of a job
|
|
47
|
+
suspend (bool, optional): suspend subsequent executions
|
|
48
|
+
successful_jobs_history_limit (int, optional): number of successful jobs to retain
|
|
49
|
+
failed_jobs_history_limit (int, optional): number of failed jobs to retain
|
|
50
|
+
starting_deadline_seconds (int, optional): deadline in seconds, for starting a job, in case it does not
|
|
51
|
+
start at scheduled time
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
"""
|
|
55
|
+
super().__init__(
|
|
56
|
+
name=name,
|
|
57
|
+
namespace=namespace,
|
|
58
|
+
client=client,
|
|
59
|
+
teardown=teardown,
|
|
60
|
+
privileged_client=privileged_client,
|
|
61
|
+
yaml_file=yaml_file,
|
|
62
|
+
delete_timeout=delete_timeout,
|
|
63
|
+
**kwargs,
|
|
64
|
+
)
|
|
65
|
+
self.job_template = job_template
|
|
66
|
+
self.schedule = schedule
|
|
67
|
+
self.timezone = timezone
|
|
68
|
+
self.concurrency_policy = concurrency_policy
|
|
69
|
+
self.suspend = suspend
|
|
70
|
+
self.successful_jobs_history_limit = successful_jobs_history_limit
|
|
71
|
+
self.failed_jobs_history_limit = failed_jobs_history_limit
|
|
72
|
+
self.starting_deadline_seconds = starting_deadline_seconds
|
|
73
|
+
|
|
74
|
+
def to_dict(self):
|
|
75
|
+
super().to_dict()
|
|
76
|
+
if not self.yaml_file:
|
|
77
|
+
if not (self.job_template and self.schedule):
|
|
78
|
+
raise ValueError(
|
|
79
|
+
"yaml_file or parameters 'job_template' and 'schedule' are required."
|
|
80
|
+
)
|
|
81
|
+
self.res.update(
|
|
82
|
+
{
|
|
83
|
+
"spec": {
|
|
84
|
+
"jobTemplate": self.job_template,
|
|
85
|
+
"schedule": self.schedule,
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
)
|
|
89
|
+
if self.timezone:
|
|
90
|
+
self.res["spec"]["timezone"] = self.timezone
|
|
91
|
+
if self.suspend:
|
|
92
|
+
self.res["spec"]["suspend"] = self.suspend
|
|
93
|
+
if self.successful_jobs_history_limit:
|
|
94
|
+
self.res["spec"][
|
|
95
|
+
"successfulJobsHistoryLimit"
|
|
96
|
+
] = self.successful_jobs_history_limit
|
|
97
|
+
if self.failed_jobs_history_limit:
|
|
98
|
+
self.res["spec"][
|
|
99
|
+
"failedJobsHistoryLimit"
|
|
100
|
+
] = self.failed_jobs_history_limit
|
|
101
|
+
if self.concurrency_policy:
|
|
102
|
+
self.res["spec"]["concurrencyPolicy"] = self.concurrency_policy
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
from ocp_resources.constants import TIMEOUT_4MINUTES
|
|
2
|
+
from ocp_resources.resource import NamespacedResource
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
class CSIStorageCapacity(NamespacedResource):
|
|
6
|
+
"""
|
|
7
|
+
CSIStorageCapacity object. API reference:
|
|
8
|
+
https://kubernetes.io/docs/reference/kubernetes-api/config-and-storage-resources/csi-storage-capacity-v1/#CSIStorageCapacity
|
|
9
|
+
"""
|
|
10
|
+
|
|
11
|
+
api_group = NamespacedResource.ApiGroup.STORAGE_K8S_IO
|
|
12
|
+
|
|
13
|
+
def __init__(
|
|
14
|
+
self,
|
|
15
|
+
name=None,
|
|
16
|
+
namespace=None,
|
|
17
|
+
client=None,
|
|
18
|
+
capacity=None,
|
|
19
|
+
maximum_volume_size=None,
|
|
20
|
+
node_topology=None,
|
|
21
|
+
storage_class_name=None,
|
|
22
|
+
teardown=True,
|
|
23
|
+
privileged_client=None,
|
|
24
|
+
yaml_file=None,
|
|
25
|
+
delete_timeout=TIMEOUT_4MINUTES,
|
|
26
|
+
**kwargs,
|
|
27
|
+
):
|
|
28
|
+
"""
|
|
29
|
+
Args:
|
|
30
|
+
name (str): Name of the CSIStorageCapacity resource
|
|
31
|
+
namespace (str): Namespace of CSIStorageCapacity resource
|
|
32
|
+
client: (DynamicClient): DynamicClient for api calls
|
|
33
|
+
capacity (str, optional): value reported by the csi driver
|
|
34
|
+
maximum_volume_size (str, optional): maximum volume size reported by csi driver
|
|
35
|
+
storage_class_name (str): storage class name
|
|
36
|
+
node_topology (dict, optional): defines which node has access to the storage for which capacity
|
|
37
|
+
was reported
|
|
38
|
+
Example:
|
|
39
|
+
node_topology: {'matchLabels': {'topology.hostpath.csi/node': 'c01-dbn-413-4c48b-worker-0-pmtv8'}}
|
|
40
|
+
teardown (bool): Indicates if the resource should be torn down at the end
|
|
41
|
+
privileged_client (DynamicClient): Privileged client for api calls
|
|
42
|
+
yaml_file (str): yaml file for the resource.
|
|
43
|
+
delete_timeout (int): timeout associated with delete action
|
|
44
|
+
"""
|
|
45
|
+
super().__init__(
|
|
46
|
+
name=name,
|
|
47
|
+
namespace=namespace,
|
|
48
|
+
client=client,
|
|
49
|
+
teardown=teardown,
|
|
50
|
+
privileged_client=privileged_client,
|
|
51
|
+
yaml_file=yaml_file,
|
|
52
|
+
delete_timeout=delete_timeout,
|
|
53
|
+
**kwargs,
|
|
54
|
+
)
|
|
55
|
+
self.capacity = capacity
|
|
56
|
+
self.node_topology = node_topology
|
|
57
|
+
self.storage_class_name = storage_class_name
|
|
58
|
+
self.maximum_volume_size = maximum_volume_size
|
|
59
|
+
|
|
60
|
+
def to_dict(self):
|
|
61
|
+
super().to_dict()
|
|
62
|
+
if not self.yaml_file:
|
|
63
|
+
if not self.storage_class_name:
|
|
64
|
+
raise ValueError(
|
|
65
|
+
"yaml_file or parameter 'storage_class_name' is required."
|
|
66
|
+
)
|
|
67
|
+
self.res.update(
|
|
68
|
+
{
|
|
69
|
+
"storageClassName": self.storage_class_name,
|
|
70
|
+
}
|
|
71
|
+
)
|
|
72
|
+
if self.maximum_volume_size:
|
|
73
|
+
self.res["maximumVolumeSize"] = self.maximum_volume_size
|
|
74
|
+
if self.node_topology:
|
|
75
|
+
self.res["nodeTopology"] = self.node_topology
|
|
76
|
+
if self.capacity:
|
|
77
|
+
self.res["capacity"] = self.capacity
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
from ocp_resources.constants import TIMEOUT_4MINUTES
|
|
2
|
+
from ocp_resources.resource import NamespacedResource
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
class EndpointSlice(NamespacedResource):
|
|
6
|
+
"""
|
|
7
|
+
EndpointSlice object. API reference:
|
|
8
|
+
https://kubernetes.io/docs/reference/kubernetes-api/service-resources/endpoint-slice-v1/
|
|
9
|
+
"""
|
|
10
|
+
|
|
11
|
+
api_group = NamespacedResource.ApiGroup.DISCOVERY_K8S_IO
|
|
12
|
+
|
|
13
|
+
def __init__(
|
|
14
|
+
self,
|
|
15
|
+
name=None,
|
|
16
|
+
namespace=None,
|
|
17
|
+
client=None,
|
|
18
|
+
address_type=None,
|
|
19
|
+
endpoints=None,
|
|
20
|
+
ports=None,
|
|
21
|
+
teardown=True,
|
|
22
|
+
privileged_client=None,
|
|
23
|
+
yaml_file=None,
|
|
24
|
+
delete_timeout=TIMEOUT_4MINUTES,
|
|
25
|
+
**kwargs,
|
|
26
|
+
):
|
|
27
|
+
"""
|
|
28
|
+
Args:
|
|
29
|
+
name (str): Name of the EndpointSlice resource
|
|
30
|
+
namespace (str): Namespace of EndpointSlice resource
|
|
31
|
+
client: (DynamicClient): DynamicClient for api calls
|
|
32
|
+
address_type (string): Type of address carried by this endpoint
|
|
33
|
+
endpoints (list): List of unique endpoints in this slice
|
|
34
|
+
ports (list, optional): List of port numbers available on the related ip addresses
|
|
35
|
+
teardown (bool): Indicates if the resource should be torn down at the end
|
|
36
|
+
privileged_client (DynamicClient): Privileged client for api calls
|
|
37
|
+
yaml_file (str): yaml file for the resource.
|
|
38
|
+
delete_timeout (int): timeout associated with delete action
|
|
39
|
+
"""
|
|
40
|
+
super().__init__(
|
|
41
|
+
name=name,
|
|
42
|
+
namespace=namespace,
|
|
43
|
+
client=client,
|
|
44
|
+
teardown=teardown,
|
|
45
|
+
privileged_client=privileged_client,
|
|
46
|
+
yaml_file=yaml_file,
|
|
47
|
+
delete_timeout=delete_timeout,
|
|
48
|
+
**kwargs,
|
|
49
|
+
)
|
|
50
|
+
self.address_type = address_type
|
|
51
|
+
self.endpoints = endpoints
|
|
52
|
+
self.ports = ports
|
|
53
|
+
|
|
54
|
+
def to_dict(self):
|
|
55
|
+
super().to_dict()
|
|
56
|
+
if not self.yaml_file:
|
|
57
|
+
if not (self.address_type and self.endpoints):
|
|
58
|
+
raise ValueError(
|
|
59
|
+
"yaml_file or parameters 'address_type' and 'endpoints' are required."
|
|
60
|
+
)
|
|
61
|
+
self.res.update(
|
|
62
|
+
{
|
|
63
|
+
"addressTypes": self.address_type,
|
|
64
|
+
"endpoints": self.endpoints,
|
|
65
|
+
}
|
|
66
|
+
)
|
|
67
|
+
if self.ports:
|
|
68
|
+
self.res["ports"] = self.ports
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
from ocp_resources.resource import Resource
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
class ImageContentSourcePolicy(Resource):
|
|
5
|
+
"""
|
|
6
|
+
ICSP object, inherited from Resource.
|
|
7
|
+
"""
|
|
8
|
+
|
|
9
|
+
api_group = Resource.ApiGroup.OPERATOR_OPENSHIFT_IO
|
|
10
|
+
|
|
11
|
+
def __init__(self, repository_digest_mirrors, **kwargs):
|
|
12
|
+
"""
|
|
13
|
+
Create/Manage ICSP configuration object. API reference:
|
|
14
|
+
https://docs.openshift.com/container-platform/4.12/rest_api/operator_apis/imagecontentsourcepolicy-operator-openshift-io-v1alpha1.html
|
|
15
|
+
|
|
16
|
+
Args:
|
|
17
|
+
repository_digest_mirrors (list of dict):
|
|
18
|
+
e.g. [{source: <str>, mirrors: <list>}, ..., {source: <str>, mirrors: <list>}]
|
|
19
|
+
- source - the repository that users refer to, e.g. in image pull specifications
|
|
20
|
+
- mirrors - one or more repositories (str) that may also contain the same images. The order
|
|
21
|
+
of mirrors in this list is treated as the user’s desired priority
|
|
22
|
+
"""
|
|
23
|
+
self.repository_digest_mirrors = repository_digest_mirrors
|
|
24
|
+
super().__init__(**kwargs)
|
|
25
|
+
|
|
26
|
+
def to_dict(self):
|
|
27
|
+
super().to_dict()
|
|
28
|
+
if not self.yaml_file:
|
|
29
|
+
if not self.repository_digest_mirrors:
|
|
30
|
+
raise ValueError("repository_digest_mirrors must be defined")
|
|
31
|
+
self.res["spec"] = {
|
|
32
|
+
"repositoryDigestMirrors": self.repository_digest_mirrors
|
|
33
|
+
}
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
from ocp_resources.constants import TIMEOUT_4MINUTES
|
|
2
|
+
from ocp_resources.resource import NamespacedResource
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
class Lease(NamespacedResource):
|
|
6
|
+
"""
|
|
7
|
+
Lease object. API reference:
|
|
8
|
+
https://kubernetes.io/docs/reference/kubernetes-api/cluster-resources/lease-v1/
|
|
9
|
+
"""
|
|
10
|
+
|
|
11
|
+
api_group = NamespacedResource.ApiGroup.COORDINATION_K8S_IO
|
|
12
|
+
|
|
13
|
+
def __init__(
|
|
14
|
+
self,
|
|
15
|
+
name=None,
|
|
16
|
+
namespace=None,
|
|
17
|
+
client=None,
|
|
18
|
+
teardown=True,
|
|
19
|
+
privileged_client=None,
|
|
20
|
+
yaml_file=None,
|
|
21
|
+
delete_timeout=TIMEOUT_4MINUTES,
|
|
22
|
+
holder_identity=None,
|
|
23
|
+
acquire_time=None,
|
|
24
|
+
renew_time=None,
|
|
25
|
+
lease_duration_seconds=None,
|
|
26
|
+
lease_transitions=None,
|
|
27
|
+
**kwargs,
|
|
28
|
+
):
|
|
29
|
+
"""
|
|
30
|
+
Args:
|
|
31
|
+
name (str): Name of the Lease resource
|
|
32
|
+
namespace (str): Namespace of Lease resource
|
|
33
|
+
client: (DynamicClient): DynamicClient for api calls
|
|
34
|
+
teardown (bool): Indicates if the resource should be torn down at the end
|
|
35
|
+
holder_identity (str, optional): identify of the holder of the current lease
|
|
36
|
+
lease_duration_seconds (int, optional): duration for which candidate of a lease needs to wait to acquire it
|
|
37
|
+
lease_transitions (int, optional): number of transitions of a lease between holders.
|
|
38
|
+
acquire_time (time, optional): when the current lease was acquired
|
|
39
|
+
renew_time (time, optional): when current holder of the lease has last updated it
|
|
40
|
+
privileged_client (DynamicClient): Privileged client for api calls
|
|
41
|
+
yaml_file (str): yaml file for the resource.
|
|
42
|
+
delete_timeout (int): timeout associated with delete action
|
|
43
|
+
"""
|
|
44
|
+
super().__init__(
|
|
45
|
+
name=name,
|
|
46
|
+
namespace=namespace,
|
|
47
|
+
client=client,
|
|
48
|
+
teardown=teardown,
|
|
49
|
+
privileged_client=privileged_client,
|
|
50
|
+
yaml_file=yaml_file,
|
|
51
|
+
delete_timeout=delete_timeout,
|
|
52
|
+
**kwargs,
|
|
53
|
+
)
|
|
54
|
+
self.holder_identity = holder_identity
|
|
55
|
+
self.lease_transitions = lease_transitions
|
|
56
|
+
self.lease_duration_seconds = lease_duration_seconds
|
|
57
|
+
self.acquire_time = acquire_time
|
|
58
|
+
self.renew_time = renew_time
|
|
59
|
+
|
|
60
|
+
def to_dict(self):
|
|
61
|
+
super().to_dict()
|
|
62
|
+
if not self.yaml_file:
|
|
63
|
+
if self.acquire_time:
|
|
64
|
+
self.res["spec"]["acquireTime"] = self.acquire_time
|
|
65
|
+
if self.renew_time:
|
|
66
|
+
self.res["spec"]["renewTime"] = self.renew_time
|
|
67
|
+
if self.holder_identity:
|
|
68
|
+
self.res["spec"]["holderIdentity"] = self.holder_identity
|
|
69
|
+
if self.lease_duration_seconds:
|
|
70
|
+
self.res["spec"]["leaseDurationSeconds"] = self.lease_duration_seconds
|
|
71
|
+
if self.lease_transitions:
|
|
72
|
+
self.res["spec"]["leaseTransitions"] = self.lease_transitions
|
|
@@ -14,12 +14,9 @@ class Node(Resource):
|
|
|
14
14
|
@property
|
|
15
15
|
def kubelet_ready(self):
|
|
16
16
|
return any(
|
|
17
|
-
[
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
if stat["reason"] == "KubeletReady"
|
|
21
|
-
and stat["status"] == self.Condition.Status.TRUE
|
|
22
|
-
]
|
|
17
|
+
stat["reason"] == "KubeletReady"
|
|
18
|
+
and stat["status"] == self.Condition.Status.TRUE
|
|
19
|
+
for stat in self.instance.status.conditions
|
|
23
20
|
)
|
|
24
21
|
|
|
25
22
|
@property
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# API reference: https://tekton.dev/docs/pipelines/pipelines/
|
|
2
|
+
|
|
3
|
+
from ocp_resources.resource import NamespacedResource
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
class Pipeline(NamespacedResource):
|
|
7
|
+
api_group = NamespacedResource.ApiGroup.TEKTON_DEV
|
|
8
|
+
|
|
9
|
+
def __init__(
|
|
10
|
+
self,
|
|
11
|
+
name=None,
|
|
12
|
+
namespace=None,
|
|
13
|
+
tasks=None,
|
|
14
|
+
params=None,
|
|
15
|
+
final_parallel_tasks=None,
|
|
16
|
+
client=None,
|
|
17
|
+
yaml_file=None,
|
|
18
|
+
**kwargs,
|
|
19
|
+
):
|
|
20
|
+
"""
|
|
21
|
+
Args:
|
|
22
|
+
name (str): Name of the pipeline
|
|
23
|
+
namespace (str): Namespace of the pipeline
|
|
24
|
+
tasks (str, optional): actions to perform in pipeline
|
|
25
|
+
client: (DynamicClient): DynamicClient to use.
|
|
26
|
+
params (dict, optional): params to support pipelines.
|
|
27
|
+
params can be set/changed based on tasks.
|
|
28
|
+
example: 'spec': {'params': [{'name': 'sourceTemplateName','type': 'string','default':'openshift'},
|
|
29
|
+
{'name': 'sourceTemplateNamespace', 'type':'string', 'description': 'Namespace pf template'}]}
|
|
30
|
+
final_parallel_tasks (list, optional): a list of one or more to be executed in parallel after all other
|
|
31
|
+
tasks have completed in parallel.
|
|
32
|
+
spec section can't be empty. It requires at least one optional field.
|
|
33
|
+
"""
|
|
34
|
+
super().__init__(
|
|
35
|
+
name=name,
|
|
36
|
+
namespace=namespace,
|
|
37
|
+
client=client,
|
|
38
|
+
**kwargs,
|
|
39
|
+
)
|
|
40
|
+
# TODO: Add a check for tasks when bug https://issues.redhat.com/browse/SRVKP-3019 is resolved.
|
|
41
|
+
self.tasks = tasks
|
|
42
|
+
self.params = params
|
|
43
|
+
self.final_parallel_tasks = final_parallel_tasks
|
|
44
|
+
|
|
45
|
+
def to_dict(self):
|
|
46
|
+
super().to_dict()
|
|
47
|
+
if not self.yaml_file:
|
|
48
|
+
if not (self.tasks or self.params or self.final_parallel_tasks):
|
|
49
|
+
raise ValueError(
|
|
50
|
+
"spec is expected to have at least one of the optional fields, got none"
|
|
51
|
+
)
|
|
52
|
+
self.res["spec"] = {}
|
|
53
|
+
if self.params:
|
|
54
|
+
self.res["spec"]["params"] = self.params
|
|
55
|
+
if self.tasks:
|
|
56
|
+
self.res["spec"]["tasks"] = self.tasks
|
|
57
|
+
if self.final_parallel_tasks:
|
|
58
|
+
self.res["spec"]["finally"] = self.final_parallel_tasks
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
from ocp_resources.resource import NamespacedResource
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
class PodMetrics(NamespacedResource):
|
|
5
|
+
"""
|
|
6
|
+
PodMetrics object. API reference:
|
|
7
|
+
This resource is managed by: https://github.com/kubernetes-sigs/metrics-server and is a built-in resource
|
|
8
|
+
"""
|
|
9
|
+
|
|
10
|
+
api_group = NamespacedResource.ApiGroup.METRICS_K8S_IO
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/resource.py
RENAMED
|
@@ -239,7 +239,9 @@ class Resource:
|
|
|
239
239
|
CLONE_KUBEVIRT_IO = "clone.kubevirt.io"
|
|
240
240
|
CONFIG_OPENSHIFT_IO = "config.openshift.io"
|
|
241
241
|
CONSOLE_OPENSHIFT_IO = "console.openshift.io"
|
|
242
|
+
COORDINATION_K8S_IO = "coordination.k8s.io"
|
|
242
243
|
DATA_IMPORT_CRON_TEMPLATE_KUBEVIRT_IO = "dataimportcrontemplate.kubevirt.io"
|
|
244
|
+
DISCOVERY_K8S_IO = "discovery.k8s.io"
|
|
243
245
|
EVENTS_K8S_IO = "events.k8s.io"
|
|
244
246
|
EXPORT_KUBEVIRT_IO = "export.kubevirt.io"
|
|
245
247
|
FORKLIFT_KONVEYOR_IO = "forklift.konveyor.io"
|
|
@@ -259,6 +261,7 @@ class Resource:
|
|
|
259
261
|
MACHINECONFIGURATION_OPENSHIFT_IO = "machineconfiguration.openshift.io"
|
|
260
262
|
MAISTRA_IO = "maistra.io"
|
|
261
263
|
METALLB_IO = "metallb.io"
|
|
264
|
+
METRICS_K8S_IO = "metrics.k8s.io"
|
|
262
265
|
MIGRATIONS_KUBEVIRT_IO = "migrations.kubevirt.io"
|
|
263
266
|
MONITORING_COREOS_COM = "monitoring.coreos.com"
|
|
264
267
|
NETWORKADDONSOPERATOR_NETWORK_KUBEVIRT_IO = (
|
|
@@ -322,6 +325,7 @@ class Resource:
|
|
|
322
325
|
context=None,
|
|
323
326
|
label=None,
|
|
324
327
|
timeout_seconds=TIMEOUT_1MINUTE,
|
|
328
|
+
api_group=None,
|
|
325
329
|
):
|
|
326
330
|
"""
|
|
327
331
|
Create an API resource
|
|
@@ -340,8 +344,10 @@ class Resource:
|
|
|
340
344
|
context (str): Context name for connecting to remote cluster.
|
|
341
345
|
timeout_seconds (int): timeout for a get api call, call out be terminated after this many seconds
|
|
342
346
|
label (dict): Resource labels
|
|
347
|
+
api_group (str): Resource API group; will overwrite API group definition in resource class
|
|
343
348
|
|
|
344
349
|
"""
|
|
350
|
+
self.api_group = api_group or self.api_group
|
|
345
351
|
if not self.api_group and not self.api_version:
|
|
346
352
|
raise NotImplementedError(
|
|
347
353
|
"Subclasses of Resource require self.api_group or self.api_version to be defined"
|
|
@@ -69,8 +69,7 @@ class VirtualMachineRestore(NamespacedResource):
|
|
|
69
69
|
wait_timeout=timeout,
|
|
70
70
|
sleep=1,
|
|
71
71
|
exceptions_dict=PROTOCOL_ERROR_EXCEPTION_DICT,
|
|
72
|
-
func=lambda: self.instance.get("status", {}).get("complete",
|
|
73
|
-
== status,
|
|
72
|
+
func=lambda: self.instance.get("status", {}).get("complete") == status,
|
|
74
73
|
)
|
|
75
74
|
for sample in samples:
|
|
76
75
|
if sample:
|
|
@@ -66,8 +66,7 @@ class VirtualMachineSnapshot(NamespacedResource):
|
|
|
66
66
|
wait_timeout=timeout,
|
|
67
67
|
sleep=1,
|
|
68
68
|
exceptions_dict=PROTOCOL_ERROR_EXCEPTION_DICT,
|
|
69
|
-
func=lambda: self.instance.get("status", {}).get("readyToUse",
|
|
70
|
-
== status,
|
|
69
|
+
func=lambda: self.instance.get("status", {}).get("readyToUse") == status,
|
|
71
70
|
)
|
|
72
71
|
for sample in samples:
|
|
73
72
|
if sample:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: openshift-python-wrapper
|
|
3
|
-
Version: 4.13.
|
|
3
|
+
Version: 4.13.12
|
|
4
4
|
Summary: Wrapper around https://github.com/openshift/openshift-restclient-python
|
|
5
5
|
Author-email: Meni Yakove <myakove@gmail.com>, Ruth Netser <rnetser@gmail.com>
|
|
6
6
|
Project-URL: Homepage, https://github.com/RedHatQE/openshift-python-wrapper
|
|
@@ -24,6 +24,8 @@ ocp_resources/console_plugin.py
|
|
|
24
24
|
ocp_resources/console_quick_start.py
|
|
25
25
|
ocp_resources/constants.py
|
|
26
26
|
ocp_resources/controller_revision.py
|
|
27
|
+
ocp_resources/cron_job.py
|
|
28
|
+
ocp_resources/csi_storage_capacity.py
|
|
27
29
|
ocp_resources/csidriver.py
|
|
28
30
|
ocp_resources/custom_resource_definition.py
|
|
29
31
|
ocp_resources/daemonset.py
|
|
@@ -32,6 +34,7 @@ ocp_resources/data_source.py
|
|
|
32
34
|
ocp_resources/datavolume.py
|
|
33
35
|
ocp_resources/deployment.py
|
|
34
36
|
ocp_resources/destination_rule.py
|
|
37
|
+
ocp_resources/endpoint_slice.py
|
|
35
38
|
ocp_resources/endpoints.py
|
|
36
39
|
ocp_resources/event.py
|
|
37
40
|
ocp_resources/forklift_controller.py
|
|
@@ -55,6 +58,7 @@ ocp_resources/kubevirt_metrics_aggregation.py
|
|
|
55
58
|
ocp_resources/kubevirt_node_labeller_bundle.py
|
|
56
59
|
ocp_resources/kubevirt_template_validaotr.py
|
|
57
60
|
ocp_resources/l2_advertisement.py
|
|
61
|
+
ocp_resources/lease.py
|
|
58
62
|
ocp_resources/machine.py
|
|
59
63
|
ocp_resources/machine_config.py
|
|
60
64
|
ocp_resources/machine_config_pool.py
|
|
@@ -88,10 +92,12 @@ ocp_resources/package_manifest.py
|
|
|
88
92
|
ocp_resources/peer_authentication.py
|
|
89
93
|
ocp_resources/persistent_volume.py
|
|
90
94
|
ocp_resources/persistent_volume_claim.py
|
|
95
|
+
ocp_resources/pipeline.py
|
|
91
96
|
ocp_resources/pipelineruns.py
|
|
92
97
|
ocp_resources/plan.py
|
|
93
98
|
ocp_resources/pod.py
|
|
94
99
|
ocp_resources/pod_disruption_budget.py
|
|
100
|
+
ocp_resources/pod_metrics.py
|
|
95
101
|
ocp_resources/priority_class.py
|
|
96
102
|
ocp_resources/project.py
|
|
97
103
|
ocp_resources/prometheus.py
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
4.13.9
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/__init__.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/api_server.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/api_service.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/backup.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/benchmark.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/catalog_source.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/cdi_config.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/chaos_engine.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/chaos_result.py
RENAMED
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/cluster_role.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/configmap.py
RENAMED
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/console_plugin.py
RENAMED
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/constants.py
RENAMED
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/csidriver.py
RENAMED
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/daemonset.py
RENAMED
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/data_source.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/datavolume.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/deployment.py
RENAMED
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/endpoints.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/gateway.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/hyperconverged.py
RENAMED
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/image_stream.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/imagestreamtag.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/infrastructure.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/installplan.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/kubevirt.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/machine.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/machine_config.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/machine_set.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/metallb.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/migration.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/namespace.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/network.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/network_map.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/network_policy.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/nmstate.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/operator.py
RENAMED
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/operator_group.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/operator_hub.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/pipelineruns.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/priority_class.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/project.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/prometheus.py
RENAMED
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/provider.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/replicaset.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/restore.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/role_binding.py
RENAMED
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/scheduler.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/secret.py
RENAMED
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/service.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/sriov_network.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/storage_class.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/storage_map.py
RENAMED
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/subscription.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/tekton_tasks.py
RENAMED
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/ocp_resources/template.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{openshift-python-wrapper-4.13.9 → openshift-python-wrapper-4.13.12}/tests/test_resources.py
RENAMED
|
File without changes
|
|
File without changes
|