oci-cli 3.70.0__py3-none-any.whl → 3.70.1__py3-none-any.whl
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.
- oci_cli/bin/artifacts.psm1 +4 -2
- oci_cli/bin/dif.psm1 +53 -0
- oci_cli/bin/limits.psm1 +2 -2
- oci_cli/help_text_producer/data_files/text/cmdref/artifacts/container/image/list.txt +8 -0
- oci_cli/help_text_producer/data_files/text/cmdref/artifacts/container/image/lookup.txt +93 -0
- oci_cli/help_text_producer/data_files/text/cmdref/artifacts/container/image.txt +2 -0
- oci_cli/help_text_producer/data_files/text/cmdref/artifacts/container.txt +2 -0
- oci_cli/help_text_producer/data_files/text/cmdref/artifacts.txt +18 -2
- oci_cli/help_text_producer/data_files/text/cmdref/bv/volume-kms-key/update.txt +5 -0
- oci_cli/help_text_producer/data_files/text/cmdref/ce/addon-option/list.txt +6 -1
- oci_cli/help_text_producer/data_files/text/cmdref/ce/cluster-options/get.txt +4 -0
- oci_cli/help_text_producer/data_files/text/cmdref/ce/node-pool-options/get.txt +24 -0
- oci_cli/help_text_producer/data_files/text/cmdref/compute/dedicated-vm-host/create-dedicated-vm-host-compute-bare-metal-host-placement-constraint-details.txt +12 -0
- oci_cli/help_text_producer/data_files/text/cmdref/compute/dedicated-vm-host/create-dedicated-vm-host-host-group-placement-constraint-details.txt +12 -0
- oci_cli/help_text_producer/data_files/text/cmdref/compute/dedicated-vm-host/create.txt +12 -0
- oci_cli/help_text_producer/data_files/text/cmdref/compute/dedicated-vm-host/list.txt +5 -0
- oci_cli/help_text_producer/data_files/text/cmdref/compute/dedicated-vm-host-instance/list.txt +5 -0
- oci_cli/help_text_producer/data_files/text/cmdref/delegate-access-control/work-request/work-request-error/{list.txt → list-errors.txt} +5 -5
- oci_cli/help_text_producer/data_files/text/cmdref/delegate-access-control/work-request/work-request-error.txt +1 -1
- oci_cli/help_text_producer/data_files/text/cmdref/delegate-access-control/work-request.txt +1 -1
- oci_cli/help_text_producer/data_files/text/cmdref/delegate-access-control.txt +1 -1
- oci_cli/help_text_producer/data_files/text/cmdref/dif/stack/add.txt +227 -0
- oci_cli/help_text_producer/data_files/text/cmdref/dif/stack/change-compartment.txt +136 -0
- oci_cli/help_text_producer/data_files/text/cmdref/dif/stack/create.txt +262 -0
- oci_cli/help_text_producer/data_files/text/cmdref/dif/stack/delete.txt +134 -0
- oci_cli/help_text_producer/data_files/text/cmdref/dif/stack/deploy-artifacts.txt +198 -0
- oci_cli/help_text_producer/data_files/text/cmdref/dif/stack/get.txt +96 -0
- oci_cli/help_text_producer/data_files/text/cmdref/dif/stack/update.txt +274 -0
- oci_cli/help_text_producer/data_files/text/cmdref/dif/stack-collection/list-stacks.txt +142 -0
- oci_cli/help_text_producer/data_files/text/cmdref/dif/stack-collection.txt +15 -0
- oci_cli/help_text_producer/data_files/text/cmdref/dif/stack.txt +31 -0
- oci_cli/help_text_producer/data_files/text/cmdref/dif/work-request/cancel.txt +103 -0
- oci_cli/help_text_producer/data_files/text/cmdref/dif/work-request/get.txt +91 -0
- oci_cli/help_text_producer/data_files/text/cmdref/dif/work-request/list.txt +140 -0
- oci_cli/help_text_producer/data_files/text/cmdref/{organizations/work-request-log → dif/work-request-error}/list.txt +22 -9
- oci_cli/help_text_producer/data_files/text/cmdref/dif/work-request-error.txt +15 -0
- oci_cli/help_text_producer/data_files/text/cmdref/dif/work-request-log-entry/list-work-request-logs.txt +131 -0
- oci_cli/help_text_producer/data_files/text/cmdref/dif/work-request-log-entry.txt +15 -0
- oci_cli/help_text_producer/data_files/text/cmdref/dif/work-request.txt +23 -0
- oci_cli/help_text_producer/data_files/text/cmdref/dif.txt +49 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/compliance/get.txt +99 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/compliance.txt +14 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet/create-fleet-dynamic-resource-selection.txt +5 -4
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet/create-fleet-environment-fleet-details.txt +5 -4
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet/create-fleet-generic-fleet-details.txt +5 -4
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet/create-fleet-group-fleet-details.txt +5 -4
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet/create-fleet-manual-resource-selection.txt +5 -4
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet/create-fleet-product-fleet-details.txt +5 -4
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet/create.txt +5 -4
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet/update-fleet-dynamic-resource-selection.txt +10 -4
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet/update-fleet-manual-resource-selection.txt +10 -4
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet/update.txt +10 -4
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/onboarding/create.txt +26 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/onboarding/update.txt +30 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration/create-platform-configuration-credential-config-category-details.txt +26 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration/create-platform-configuration-environment-config-category-details.txt +26 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration/create-platform-configuration-lifecycle-operation-config-category-details.txt +26 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration/create-platform-configuration-patch-type-config-category-details.txt +26 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration/create-platform-configuration-product-config-category-details.txt +26 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration/create-platform-configuration-product-stack-config-category-details.txt +26 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration/create-platform-configuration-self-hosted-instance-config-category-details.txt +26 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration/create.txt +26 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration/update-platform-configuration-credential-config-category-details.txt +30 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration/update-platform-configuration-environment-config-category-details.txt +30 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration/update-platform-configuration-lifecycle-operation-config-category-details.txt +30 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration/update-platform-configuration-patch-type-config-category-details.txt +30 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration/update-platform-configuration-product-config-category-details.txt +30 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration/update-platform-configuration-product-stack-config-category-details.txt +30 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration/update-platform-configuration-self-hosted-instance-config-category-details.txt +30 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration/update.txt +26 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/platform-configuration-collection/list-platform-configurations.txt +1 -1
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/property/create.txt +26 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-admin/property/update.txt +26 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-catalog/catalog-item/configure.txt +218 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-catalog/catalog-item/create-catalog-item-catalog-git-source-config.txt +4 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-catalog/catalog-item/create-catalog-item-catalog-marketplace-source-config.txt +4 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-catalog/catalog-item/create-catalog-item-catalog-par-source-config.txt +4 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-catalog/catalog-item/create-catalog-item-catalog-source-template-config.txt +4 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-catalog/catalog-item/create.txt +4 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-catalog/catalog-item/update.txt +4 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-catalog/catalog-item-collection/list-catalog-items.txt +9 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-catalog/catalog-item-variables-definition/get.txt +97 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-catalog/catalog-item-variables-definition.txt +14 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-catalog/catalog-item.txt +2 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-catalog.txt +6 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-operations/installed-patch-collection/list-installed-patches.txt +152 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-operations/installed-patch-collection.txt +14 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-operations/inventory-record-collection/list-inventory-records.txt +4 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-operations/job-activity/get.txt +4 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-operations/recommended-patch-collection/list-recommended-patches.txt +159 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-operations/recommended-patch-collection.txt +14 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-operations/report-collection/report.txt +180 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-operations/report-collection.txt +14 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-operations/report-metadata-collection/list-report-metadata.txt +133 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-operations/report-metadata-collection.txt +14 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-operations/scheduler-execution-collection/list-scheduler-executions.txt +13 -1
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-operations/target-component-collection/list-target-components.txt +147 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-operations/target-component-collection.txt +14 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-operations/target-property-collection/list-target-properties.txt +143 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-operations/target-property-collection.txt +14 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-operations.txt +24 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/import-runbook-details/import-runbook.txt +187 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/import-runbook-details.txt +14 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/import-runbook-precheck-details/import-runbook-precheck.txt +182 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/import-runbook-precheck-details.txt +14 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/import-runbook-version-details/import-runbook-version.txt +183 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/import-runbook-version-details.txt +14 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook/export-runbook-transfer-runbook-object-storage-bucket-content-details.txt +160 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook/export-runbook-transfer-runbook-par-url-content-details.txt +147 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook/export-runbook-version-transfer-runbook-object-storage-bucket-content-details.txt +147 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook/export-runbook-version-transfer-runbook-par-url-content-details.txt +134 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook/export-runbook-version.txt +145 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook/export.txt +155 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-export/get.txt +105 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-export-dependency-collection/find-runbook-export-dependency.txt +114 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-export-dependency-collection.txt +15 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-export-status-collection/list-runbook-export-statuses.txt +135 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-export-status-collection.txt +15 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-export.txt +14 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-import/get.txt +105 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-import-dependency-collection/find-runbook-import-dependency-transfer-runbook-object-storage-bucket-content-details.txt +119 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-import-dependency-collection/find-runbook-import-dependency-transfer-runbook-par-url-content-details.txt +106 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-import-dependency-collection/find-runbook-import-dependency.txt +117 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-import-dependency-collection.txt +21 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-import-status-collection/list-runbook-import-statuses.txt +135 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-import-status-collection.txt +15 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-import.txt +14 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-version/create.txt +5 -4
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-version/update.txt +1 -1
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook-version.txt +4 -1
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks/runbook.txt +14 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-apps-management-runbooks.txt +56 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-target-collection/list-fleet-targets.txt +9 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management/fleet-target-collection/list-targets.txt +4 -0
- oci_cli/help_text_producer/data_files/text/cmdref/fleet-apps-management.txt +90 -0
- oci_cli/help_text_producer/data_files/text/cmdref/generative-ai/dedicated-ai-cluster/create.txt +10 -1
- oci_cli/help_text_producer/data_files/text/cmdref/generative-ai/imported-model/change-compartment.txt +106 -0
- oci_cli/help_text_producer/data_files/text/cmdref/generative-ai/imported-model/create-from-huggingface.txt +213 -0
- oci_cli/help_text_producer/data_files/text/cmdref/generative-ai/imported-model/create-from-objectstorage.txt +203 -0
- oci_cli/help_text_producer/data_files/text/cmdref/generative-ai/imported-model/delete.txt +131 -0
- oci_cli/help_text_producer/data_files/text/cmdref/generative-ai/imported-model/get.txt +91 -0
- oci_cli/help_text_producer/data_files/text/cmdref/generative-ai/imported-model/update.txt +183 -0
- oci_cli/help_text_producer/data_files/text/cmdref/generative-ai/imported-model-collection/list-imported-models.txt +161 -0
- oci_cli/help_text_producer/data_files/text/cmdref/generative-ai/imported-model-collection.txt +14 -0
- oci_cli/help_text_producer/data_files/text/cmdref/generative-ai/imported-model.txt +30 -0
- oci_cli/help_text_producer/data_files/text/cmdref/generative-ai/model-collection/list-models.txt +1 -1
- oci_cli/help_text_producer/data_files/text/cmdref/generative-ai.txt +18 -0
- oci_cli/help_text_producer/data_files/text/cmdref/limits/definition/list.txt +5 -5
- oci_cli/help_text_producer/data_files/text/cmdref/limits/resource-availability/get.txt +9 -5
- oci_cli/help_text_producer/data_files/text/cmdref/limits/service/list.txt +1 -1
- oci_cli/help_text_producer/data_files/text/cmdref/limits/value/list.txt +7 -3
- oci_cli/help_text_producer/data_files/text/cmdref/ocvs/work-request-error/{list-errors.txt → list.txt} +5 -5
- oci_cli/help_text_producer/data_files/text/cmdref/ocvs/work-request-error.txt +1 -1
- oci_cli/help_text_producer/data_files/text/cmdref/ocvs.txt +1 -1
- oci_cli/help_text_producer/data_files/text/cmdref/organizations/work-request-error/{list-errors.txt → list.txt} +5 -5
- oci_cli/help_text_producer/data_files/text/cmdref/organizations/work-request-error.txt +1 -1
- oci_cli/help_text_producer/data_files/text/cmdref/organizations/work-request-log-entry/list.txt +100 -0
- oci_cli/help_text_producer/data_files/text/cmdref/organizations/{work-request-log.txt → work-request-log-entry.txt} +2 -2
- oci_cli/help_text_producer/data_files/text/cmdref/organizations.txt +2 -2
- oci_cli/help_text_producer/data_files/text/cmdref/support/incident/create.txt +6 -6
- oci_cli/help_text_producer/data_files/text/cmdref/support/incident/get.txt +2 -2
- oci_cli/help_text_producer/data_files/text/cmdref/support/incident/list.txt +1 -1
- oci_cli/help_text_producer/data_files/text/cmdref/support/incident/update.txt +4 -4
- oci_cli/help_text_producer/data_files/text/cmdref/support/incident-resource-type/list.txt +3 -3
- oci_cli/help_text_producer/data_files/text/cmdref/support/validation-response/validate-user.txt +1 -1
- oci_cli/help_text_producer/data_files/text/index.txt +2 -0
- oci_cli/service_mapping.py +5 -0
- oci_cli/version.py +1 -1
- {oci_cli-3.70.0.dist-info → oci_cli-3.70.1.dist-info}/METADATA +2 -2
- {oci_cli-3.70.0.dist-info → oci_cli-3.70.1.dist-info}/RECORD +196 -114
- services/artifacts/src/oci_cli_artifacts/artifacts_cli_extended.py +4 -0
- services/artifacts/src/oci_cli_artifacts/generated/artifacts_cli.py +36 -3
- services/container_engine/src/oci_cli_container_engine/generated/containerengine_cli.py +18 -3
- services/core/src/oci_cli_blockstorage/generated/blockstorage_cli.py +4 -1
- services/core/src/oci_cli_compute/generated/compute_cli.py +35 -5
- services/dif/__init__.py +4 -0
- services/dif/src/__init__.py +4 -0
- services/dif/src/oci_cli_stack/__init__.py +4 -0
- services/dif/src/oci_cli_stack/generated/__init__.py +4 -0
- services/dif/src/oci_cli_stack/generated/client_mappings.py +14 -0
- services/dif/src/oci_cli_stack/generated/stack_cli.py +887 -0
- services/dif/src/oci_cli_stack/stack_cli_extended.py +51 -0
- services/dif/tests/__init__.py +4 -0
- services/fleet_apps_management/src/oci_cli_fleet_apps_management/generated/fleetappsmanagement_cli.py +63 -15
- services/fleet_apps_management/src/oci_cli_fleet_apps_management_admin/generated/fleetappsmanagementadmin_cli.py +265 -65
- services/fleet_apps_management/src/oci_cli_fleet_apps_management_catalog/generated/fleetappsmanagementcatalog_cli.py +154 -7
- services/fleet_apps_management/src/oci_cli_fleet_apps_management_operations/generated/fleetappsmanagementoperations_cli.py +473 -31
- services/fleet_apps_management/src/oci_cli_fleet_apps_management_runbooks/generated/fleetappsmanagementrunbooks_cli.py +1055 -34
- services/generative_ai/src/oci_cli_generative_ai/generated/generativeai_cli.py +640 -59
- services/generative_ai/src/oci_cli_generative_ai/generativeai_cli_extended.py +107 -0
- services/limits/src/oci_cli_limits/generated/limits_cli.py +15 -9
- {oci_cli-3.70.0.dist-info → oci_cli-3.70.1.dist-info}/LICENSE.txt +0 -0
- {oci_cli-3.70.0.dist-info → oci_cli-3.70.1.dist-info}/THIRD_PARTY_LICENSES.txt +0 -0
- {oci_cli-3.70.0.dist-info → oci_cli-3.70.1.dist-info}/WHEEL +0 -0
- {oci_cli-3.70.0.dist-info → oci_cli-3.70.1.dist-info}/entry_points.txt +0 -0
- {oci_cli-3.70.0.dist-info → oci_cli-3.70.1.dist-info}/top_level.txt +0 -0
|
@@ -22,27 +22,81 @@ def fleet_apps_management_runbooks_root_group():
|
|
|
22
22
|
pass
|
|
23
23
|
|
|
24
24
|
|
|
25
|
+
@click.command(cli_util.override('fleet_apps_management_runbooks.import_runbook_details_group.command_name', 'import-runbook-details'), cls=CommandGroupWithAlias, help="""Request to Import Runbook.""")
|
|
26
|
+
@cli_util.help_option_group
|
|
27
|
+
def import_runbook_details_group():
|
|
28
|
+
pass
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
@click.command(cli_util.override('fleet_apps_management_runbooks.runbook_import_status_collection_group.command_name', 'runbook-import-status-collection'), cls=CommandGroupWithAlias, help="""Results of a runbook search. Contains RunbookImportStatusSummary items and other information.""")
|
|
32
|
+
@cli_util.help_option_group
|
|
33
|
+
def runbook_import_status_collection_group():
|
|
34
|
+
pass
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
@click.command(cli_util.override('fleet_apps_management_runbooks.import_runbook_version_details_group.command_name', 'import-runbook-version-details'), cls=CommandGroupWithAlias, help="""Request to Export Runbook Version.""")
|
|
38
|
+
@cli_util.help_option_group
|
|
39
|
+
def import_runbook_version_details_group():
|
|
40
|
+
pass
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
@click.command(cli_util.override('fleet_apps_management_runbooks.import_runbook_precheck_details_group.command_name', 'import-runbook-precheck-details'), cls=CommandGroupWithAlias, help="""Request for precheck of Runbook import.""")
|
|
44
|
+
@cli_util.help_option_group
|
|
45
|
+
def import_runbook_precheck_details_group():
|
|
46
|
+
pass
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
@click.command(cli_util.override('fleet_apps_management_runbooks.runbook_import_group.command_name', 'runbook-import'), cls=CommandGroupWithAlias, help="""Runbook Import Status check details.""")
|
|
50
|
+
@cli_util.help_option_group
|
|
51
|
+
def runbook_import_group():
|
|
52
|
+
pass
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
@click.command(cli_util.override('fleet_apps_management_runbooks.runbook_version_group.command_name', 'runbook-version'), cls=CommandGroupWithAlias, help="""Version for the runbook. Versioning runbooks in Fleet Application Management involve assigning unique identifiers or version numbers to different iterations of the runbook to track changes, improvements, and updates over time.""")
|
|
56
|
+
@cli_util.help_option_group
|
|
57
|
+
def runbook_version_group():
|
|
58
|
+
pass
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
@click.command(cli_util.override('fleet_apps_management_runbooks.runbook_import_dependency_collection_group.command_name', 'runbook-import-dependency-collection'), cls=CommandGroupWithAlias, help="""Results of a find runbook import dependency. Contains RunbookTransferDependencySummary.""")
|
|
62
|
+
@cli_util.help_option_group
|
|
63
|
+
def runbook_import_dependency_collection_group():
|
|
64
|
+
pass
|
|
65
|
+
|
|
66
|
+
|
|
67
|
+
@click.command(cli_util.override('fleet_apps_management_runbooks.task_record_group.command_name', 'task-record'), cls=CommandGroupWithAlias, help="""Attributes of a task record.""")
|
|
68
|
+
@cli_util.help_option_group
|
|
69
|
+
def task_record_group():
|
|
70
|
+
pass
|
|
71
|
+
|
|
72
|
+
|
|
25
73
|
@click.command(cli_util.override('fleet_apps_management_runbooks.task_record_collection_group.command_name', 'task-record-collection'), cls=CommandGroupWithAlias, help="""Results of a task record search. Contains boh TaskRecordSummary items and other information, such as metadata.""")
|
|
26
74
|
@cli_util.help_option_group
|
|
27
75
|
def task_record_collection_group():
|
|
28
76
|
pass
|
|
29
77
|
|
|
30
78
|
|
|
31
|
-
@click.command(cli_util.override('fleet_apps_management_runbooks.
|
|
79
|
+
@click.command(cli_util.override('fleet_apps_management_runbooks.runbook_export_status_collection_group.command_name', 'runbook-export-status-collection'), cls=CommandGroupWithAlias, help="""Results of a runbook search. Contains RunbookExportStatusSummary items and other information.""")
|
|
32
80
|
@cli_util.help_option_group
|
|
33
|
-
def
|
|
81
|
+
def runbook_export_status_collection_group():
|
|
34
82
|
pass
|
|
35
83
|
|
|
36
84
|
|
|
37
|
-
@click.command(cli_util.override('fleet_apps_management_runbooks.
|
|
85
|
+
@click.command(cli_util.override('fleet_apps_management_runbooks.runbook_export_dependency_collection_group.command_name', 'runbook-export-dependency-collection'), cls=CommandGroupWithAlias, help="""Results of a find runbook export dependency. Contains RunbookExportDependencySummary.""")
|
|
38
86
|
@cli_util.help_option_group
|
|
39
|
-
def
|
|
87
|
+
def runbook_export_dependency_collection_group():
|
|
88
|
+
pass
|
|
89
|
+
|
|
90
|
+
|
|
91
|
+
@click.command(cli_util.override('fleet_apps_management_runbooks.runbook_version_collection_group.command_name', 'runbook-version-collection'), cls=CommandGroupWithAlias, help="""Results of a RunbookVersion search. Contains RunbookVersionSummary.""")
|
|
92
|
+
@cli_util.help_option_group
|
|
93
|
+
def runbook_version_collection_group():
|
|
40
94
|
pass
|
|
41
95
|
|
|
42
96
|
|
|
43
|
-
@click.command(cli_util.override('fleet_apps_management_runbooks.
|
|
97
|
+
@click.command(cli_util.override('fleet_apps_management_runbooks.runbook_collection_group.command_name', 'runbook-collection'), cls=CommandGroupWithAlias, help="""Results of a runbook search. Contains RunbookSummary items and other information, such as metadata.""")
|
|
44
98
|
@cli_util.help_option_group
|
|
45
|
-
def
|
|
99
|
+
def runbook_collection_group():
|
|
46
100
|
pass
|
|
47
101
|
|
|
48
102
|
|
|
@@ -52,19 +106,28 @@ def runbook_group():
|
|
|
52
106
|
pass
|
|
53
107
|
|
|
54
108
|
|
|
55
|
-
@click.command(cli_util.override('fleet_apps_management_runbooks.
|
|
109
|
+
@click.command(cli_util.override('fleet_apps_management_runbooks.runbook_export_group.command_name', 'runbook-export'), cls=CommandGroupWithAlias, help="""Runbook Export Status check details.""")
|
|
56
110
|
@cli_util.help_option_group
|
|
57
|
-
def
|
|
111
|
+
def runbook_export_group():
|
|
58
112
|
pass
|
|
59
113
|
|
|
60
114
|
|
|
61
115
|
fleet_apps_management_service_cli.fleet_apps_management_service_group.add_command(fleet_apps_management_runbooks_root_group)
|
|
116
|
+
fleet_apps_management_runbooks_root_group.add_command(import_runbook_details_group)
|
|
117
|
+
fleet_apps_management_runbooks_root_group.add_command(runbook_import_status_collection_group)
|
|
118
|
+
fleet_apps_management_runbooks_root_group.add_command(import_runbook_version_details_group)
|
|
119
|
+
fleet_apps_management_runbooks_root_group.add_command(import_runbook_precheck_details_group)
|
|
120
|
+
fleet_apps_management_runbooks_root_group.add_command(runbook_import_group)
|
|
121
|
+
fleet_apps_management_runbooks_root_group.add_command(runbook_version_group)
|
|
122
|
+
fleet_apps_management_runbooks_root_group.add_command(runbook_import_dependency_collection_group)
|
|
123
|
+
fleet_apps_management_runbooks_root_group.add_command(task_record_group)
|
|
62
124
|
fleet_apps_management_runbooks_root_group.add_command(task_record_collection_group)
|
|
125
|
+
fleet_apps_management_runbooks_root_group.add_command(runbook_export_status_collection_group)
|
|
126
|
+
fleet_apps_management_runbooks_root_group.add_command(runbook_export_dependency_collection_group)
|
|
63
127
|
fleet_apps_management_runbooks_root_group.add_command(runbook_version_collection_group)
|
|
64
128
|
fleet_apps_management_runbooks_root_group.add_command(runbook_collection_group)
|
|
65
|
-
fleet_apps_management_runbooks_root_group.add_command(runbook_version_group)
|
|
66
129
|
fleet_apps_management_runbooks_root_group.add_command(runbook_group)
|
|
67
|
-
fleet_apps_management_runbooks_root_group.add_command(
|
|
130
|
+
fleet_apps_management_runbooks_root_group.add_command(runbook_export_group)
|
|
68
131
|
|
|
69
132
|
|
|
70
133
|
@runbook_group.command(name=cli_util.override('fleet_apps_management_runbooks.change_runbook_compartment.command_name', 'change-compartment'), help=u"""Moves a Runbook into a different compartment within the same tenancy. For information about moving resources between compartments, see [Moving Resources to a Different Compartment]. \n[Command Reference](changeRunbookCompartment)""")
|
|
@@ -282,10 +345,10 @@ def create_runbook(ctx, from_json, wait_for_state, max_wait_seconds, wait_interv
|
|
|
282
345
|
cli_util.render_response(result, ctx)
|
|
283
346
|
|
|
284
347
|
|
|
285
|
-
@runbook_version_group.command(name=cli_util.override('fleet_apps_management_runbooks.create_runbook_version.command_name', 'create'), help=u"""Add RunbookVersion in
|
|
348
|
+
@runbook_version_group.command(name=cli_util.override('fleet_apps_management_runbooks.create_runbook_version.command_name', 'create'), help=u"""Add RunbookVersion in Fleet Application Management. \n[Command Reference](createRunbookVersion)""")
|
|
286
349
|
@cli_util.option('--runbook-id', required=True, help=u"""The OCID of the resource.""")
|
|
287
350
|
@cli_util.option('--tasks', required=True, type=custom_types.CLI_COMPLEX_TYPE, help=u"""A set of tasks to execute in the runbook.""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
288
|
-
@cli_util.option('--groups', required=True, type=custom_types.CLI_COMPLEX_TYPE, help=u"""The groups of the runbook.""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
351
|
+
@cli_util.option('--groups', required=True, type=custom_types.CLI_COMPLEX_TYPE, help=u"""The groups of the runbook version.""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
289
352
|
@cli_util.option('--execution-workflow-details', required=True, type=custom_types.CLI_COMPLEX_TYPE, help=u"""""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
290
353
|
@cli_util.option('--rollback-workflow-details', type=custom_types.CLI_COMPLEX_TYPE, help=u"""""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
291
354
|
@cli_util.option('--freeform-tags', type=custom_types.CLI_COMPLEX_TYPE, help=u"""Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: `{\"bar-key\": \"value\"}`""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
@@ -588,69 +651,1027 @@ def delete_task_record(ctx, from_json, wait_for_state, max_wait_seconds, wait_in
|
|
|
588
651
|
cli_util.render_response(result, ctx)
|
|
589
652
|
|
|
590
653
|
|
|
591
|
-
@runbook_group.command(name=cli_util.override('fleet_apps_management_runbooks.
|
|
654
|
+
@runbook_group.command(name=cli_util.override('fleet_apps_management_runbooks.export_runbook.command_name', 'export'), help=u"""Export the specified version of the runbook. \n[Command Reference](exportRunbook)""")
|
|
655
|
+
@cli_util.option('--content-destination', required=True, type=custom_types.CLI_COMPLEX_TYPE, help=u"""""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
592
656
|
@cli_util.option('--runbook-id', required=True, help=u"""Unique Runbook identifier""")
|
|
593
|
-
@
|
|
657
|
+
@cli_util.option('--export-as', type=custom_types.CliCaseInsensitiveChoice(["TERRAFORM", "NON_TERRAFORM"]), help=u"""Export Runbook As Type.""")
|
|
658
|
+
@cli_util.option('--if-match', help=u"""For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value.""")
|
|
659
|
+
@cli_util.option('--wait-for-state', type=custom_types.CliCaseInsensitiveChoice(["ACCEPTED", "IN_PROGRESS", "WAITING", "NEEDS_ATTENTION", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED"]), multiple=True, help="""This operation asynchronously creates, modifies or deletes a resource and uses a work request to track the progress of the operation. Specify this option to perform the action and then wait until the work request reaches a certain state. Multiple states can be specified, returning on the first state. For example, --wait-for-state SUCCEEDED --wait-for-state FAILED would return on whichever lifecycle state is reached first. If timeout is reached, a return code of 2 is returned. For any other error, a return code of 1 is returned.""")
|
|
660
|
+
@cli_util.option('--max-wait-seconds', type=click.INT, help="""The maximum time to wait for the work request to reach the state defined by --wait-for-state. Defaults to 1200 seconds.""")
|
|
661
|
+
@cli_util.option('--wait-interval-seconds', type=click.INT, help="""Check every --wait-interval-seconds to see whether the work request has reached the state defined by --wait-for-state. Defaults to 30 seconds.""")
|
|
662
|
+
@json_skeleton_utils.get_cli_json_input_option({'content-destination': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}})
|
|
594
663
|
@cli_util.help_option
|
|
595
664
|
@click.pass_context
|
|
596
|
-
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={
|
|
665
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={'content-destination': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}})
|
|
597
666
|
@cli_util.wrap_exceptions
|
|
598
|
-
def
|
|
667
|
+
def export_runbook(ctx, from_json, wait_for_state, max_wait_seconds, wait_interval_seconds, content_destination, runbook_id, export_as, if_match):
|
|
599
668
|
|
|
600
669
|
if isinstance(runbook_id, six.string_types) and len(runbook_id.strip()) == 0:
|
|
601
670
|
raise click.UsageError('Parameter --runbook-id cannot be whitespace or empty string')
|
|
602
671
|
|
|
603
672
|
kwargs = {}
|
|
673
|
+
if if_match is not None:
|
|
674
|
+
kwargs['if_match'] = if_match
|
|
604
675
|
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
676
|
+
|
|
677
|
+
_details = {}
|
|
678
|
+
_details['contentDestination'] = cli_util.parse_json_parameter("content_destination", content_destination)
|
|
679
|
+
|
|
680
|
+
if export_as is not None:
|
|
681
|
+
_details['exportAs'] = export_as
|
|
682
|
+
|
|
605
683
|
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
606
|
-
result = client.
|
|
684
|
+
result = client.export_runbook(
|
|
607
685
|
runbook_id=runbook_id,
|
|
686
|
+
export_runbook_details=_details,
|
|
608
687
|
**kwargs
|
|
609
688
|
)
|
|
689
|
+
if wait_for_state:
|
|
690
|
+
|
|
691
|
+
if hasattr(client, 'get_work_request') and callable(getattr(client, 'get_work_request')):
|
|
692
|
+
try:
|
|
693
|
+
wait_period_kwargs = {}
|
|
694
|
+
if max_wait_seconds is not None:
|
|
695
|
+
wait_period_kwargs['max_wait_seconds'] = max_wait_seconds
|
|
696
|
+
if wait_interval_seconds is not None:
|
|
697
|
+
wait_period_kwargs['max_interval_seconds'] = wait_interval_seconds
|
|
698
|
+
if 'opc-work-request-id' not in result.headers:
|
|
699
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state')
|
|
700
|
+
cli_util.render_response(result, ctx)
|
|
701
|
+
return
|
|
702
|
+
|
|
703
|
+
click.echo('Action completed. Waiting until the work request has entered state: {}'.format(wait_for_state), file=sys.stderr)
|
|
704
|
+
result = oci.wait_until(client, client.get_work_request(result.headers['opc-work-request-id']), 'status', wait_for_state, **wait_period_kwargs)
|
|
705
|
+
except oci.exceptions.MaximumWaitTimeExceeded as e:
|
|
706
|
+
# If we fail, we should show an error, but we should still provide the information to the customer
|
|
707
|
+
click.echo('Failed to wait until the work request entered the specified state. Outputting last known resource state', file=sys.stderr)
|
|
708
|
+
cli_util.render_response(result, ctx)
|
|
709
|
+
sys.exit(2)
|
|
710
|
+
except Exception:
|
|
711
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state', file=sys.stderr)
|
|
712
|
+
cli_util.render_response(result, ctx)
|
|
713
|
+
raise
|
|
714
|
+
else:
|
|
715
|
+
click.echo('Unable to wait for the work request to enter the specified state', file=sys.stderr)
|
|
610
716
|
cli_util.render_response(result, ctx)
|
|
611
717
|
|
|
612
718
|
|
|
613
|
-
@
|
|
614
|
-
@cli_util.option('--runbook-
|
|
719
|
+
@runbook_group.command(name=cli_util.override('fleet_apps_management_runbooks.export_runbook_transfer_runbook_object_storage_bucket_content_details.command_name', 'export-runbook-transfer-runbook-object-storage-bucket-content-details'), help=u"""Export the specified version of the runbook. \n[Command Reference](exportRunbook)""")
|
|
720
|
+
@cli_util.option('--runbook-id', required=True, help=u"""Unique Runbook identifier""")
|
|
721
|
+
@cli_util.option('--content-destination-namespace-name', required=True, help=u"""Namespace.""")
|
|
722
|
+
@cli_util.option('--content-destination-bucket-name', required=True, help=u"""Bucket Name.""")
|
|
723
|
+
@cli_util.option('--export-as', type=custom_types.CliCaseInsensitiveChoice(["TERRAFORM", "NON_TERRAFORM"]), help=u"""Export Runbook As Type.""")
|
|
724
|
+
@cli_util.option('--if-match', help=u"""For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value.""")
|
|
725
|
+
@cli_util.option('--content-destination-object-name', help=u"""Object Name.""")
|
|
726
|
+
@cli_util.option('--content-destination-checksum', help=u"""md5 checksum of the artifact.""")
|
|
727
|
+
@cli_util.option('--wait-for-state', type=custom_types.CliCaseInsensitiveChoice(["ACCEPTED", "IN_PROGRESS", "WAITING", "NEEDS_ATTENTION", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED"]), multiple=True, help="""This operation asynchronously creates, modifies or deletes a resource and uses a work request to track the progress of the operation. Specify this option to perform the action and then wait until the work request reaches a certain state. Multiple states can be specified, returning on the first state. For example, --wait-for-state SUCCEEDED --wait-for-state FAILED would return on whichever lifecycle state is reached first. If timeout is reached, a return code of 2 is returned. For any other error, a return code of 1 is returned.""")
|
|
728
|
+
@cli_util.option('--max-wait-seconds', type=click.INT, help="""The maximum time to wait for the work request to reach the state defined by --wait-for-state. Defaults to 1200 seconds.""")
|
|
729
|
+
@cli_util.option('--wait-interval-seconds', type=click.INT, help="""Check every --wait-interval-seconds to see whether the work request has reached the state defined by --wait-for-state. Defaults to 30 seconds.""")
|
|
615
730
|
@json_skeleton_utils.get_cli_json_input_option({})
|
|
616
731
|
@cli_util.help_option
|
|
617
732
|
@click.pass_context
|
|
618
|
-
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={}
|
|
733
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={})
|
|
619
734
|
@cli_util.wrap_exceptions
|
|
620
|
-
def
|
|
735
|
+
def export_runbook_transfer_runbook_object_storage_bucket_content_details(ctx, from_json, wait_for_state, max_wait_seconds, wait_interval_seconds, runbook_id, content_destination_namespace_name, content_destination_bucket_name, export_as, if_match, content_destination_object_name, content_destination_checksum):
|
|
621
736
|
|
|
622
|
-
if isinstance(
|
|
623
|
-
raise click.UsageError('Parameter --runbook-
|
|
737
|
+
if isinstance(runbook_id, six.string_types) and len(runbook_id.strip()) == 0:
|
|
738
|
+
raise click.UsageError('Parameter --runbook-id cannot be whitespace or empty string')
|
|
624
739
|
|
|
625
740
|
kwargs = {}
|
|
741
|
+
if if_match is not None:
|
|
742
|
+
kwargs['if_match'] = if_match
|
|
626
743
|
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
744
|
+
|
|
745
|
+
_details = {}
|
|
746
|
+
_details['contentDestination'] = {}
|
|
747
|
+
_details['contentDestination']['namespaceName'] = content_destination_namespace_name
|
|
748
|
+
_details['contentDestination']['bucketName'] = content_destination_bucket_name
|
|
749
|
+
|
|
750
|
+
if export_as is not None:
|
|
751
|
+
_details['exportAs'] = export_as
|
|
752
|
+
|
|
753
|
+
if content_destination_object_name is not None:
|
|
754
|
+
_details['contentDestination']['objectName'] = content_destination_object_name
|
|
755
|
+
|
|
756
|
+
if content_destination_checksum is not None:
|
|
757
|
+
_details['contentDestination']['checksum'] = content_destination_checksum
|
|
758
|
+
|
|
759
|
+
_details['contentDestination']['sourceType'] = 'OBJECT_STORAGE_BUCKET'
|
|
760
|
+
|
|
627
761
|
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
628
|
-
result = client.
|
|
629
|
-
|
|
762
|
+
result = client.export_runbook(
|
|
763
|
+
runbook_id=runbook_id,
|
|
764
|
+
export_runbook_details=_details,
|
|
630
765
|
**kwargs
|
|
631
766
|
)
|
|
767
|
+
if wait_for_state:
|
|
768
|
+
|
|
769
|
+
if hasattr(client, 'get_work_request') and callable(getattr(client, 'get_work_request')):
|
|
770
|
+
try:
|
|
771
|
+
wait_period_kwargs = {}
|
|
772
|
+
if max_wait_seconds is not None:
|
|
773
|
+
wait_period_kwargs['max_wait_seconds'] = max_wait_seconds
|
|
774
|
+
if wait_interval_seconds is not None:
|
|
775
|
+
wait_period_kwargs['max_interval_seconds'] = wait_interval_seconds
|
|
776
|
+
if 'opc-work-request-id' not in result.headers:
|
|
777
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state')
|
|
778
|
+
cli_util.render_response(result, ctx)
|
|
779
|
+
return
|
|
780
|
+
|
|
781
|
+
click.echo('Action completed. Waiting until the work request has entered state: {}'.format(wait_for_state), file=sys.stderr)
|
|
782
|
+
result = oci.wait_until(client, client.get_work_request(result.headers['opc-work-request-id']), 'status', wait_for_state, **wait_period_kwargs)
|
|
783
|
+
except oci.exceptions.MaximumWaitTimeExceeded as e:
|
|
784
|
+
# If we fail, we should show an error, but we should still provide the information to the customer
|
|
785
|
+
click.echo('Failed to wait until the work request entered the specified state. Outputting last known resource state', file=sys.stderr)
|
|
786
|
+
cli_util.render_response(result, ctx)
|
|
787
|
+
sys.exit(2)
|
|
788
|
+
except Exception:
|
|
789
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state', file=sys.stderr)
|
|
790
|
+
cli_util.render_response(result, ctx)
|
|
791
|
+
raise
|
|
792
|
+
else:
|
|
793
|
+
click.echo('Unable to wait for the work request to enter the specified state', file=sys.stderr)
|
|
632
794
|
cli_util.render_response(result, ctx)
|
|
633
795
|
|
|
634
796
|
|
|
635
|
-
@
|
|
636
|
-
@cli_util.option('--
|
|
797
|
+
@runbook_group.command(name=cli_util.override('fleet_apps_management_runbooks.export_runbook_transfer_runbook_par_url_content_details.command_name', 'export-runbook-transfer-runbook-par-url-content-details'), help=u"""Export the specified version of the runbook. \n[Command Reference](exportRunbook)""")
|
|
798
|
+
@cli_util.option('--runbook-id', required=True, help=u"""Unique Runbook identifier""")
|
|
799
|
+
@cli_util.option('--content-destination-url', required=True, help=u"""PAR url.""")
|
|
800
|
+
@cli_util.option('--export-as', type=custom_types.CliCaseInsensitiveChoice(["TERRAFORM", "NON_TERRAFORM"]), help=u"""Export Runbook As Type.""")
|
|
801
|
+
@cli_util.option('--if-match', help=u"""For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value.""")
|
|
802
|
+
@cli_util.option('--wait-for-state', type=custom_types.CliCaseInsensitiveChoice(["ACCEPTED", "IN_PROGRESS", "WAITING", "NEEDS_ATTENTION", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED"]), multiple=True, help="""This operation asynchronously creates, modifies or deletes a resource and uses a work request to track the progress of the operation. Specify this option to perform the action and then wait until the work request reaches a certain state. Multiple states can be specified, returning on the first state. For example, --wait-for-state SUCCEEDED --wait-for-state FAILED would return on whichever lifecycle state is reached first. If timeout is reached, a return code of 2 is returned. For any other error, a return code of 1 is returned.""")
|
|
803
|
+
@cli_util.option('--max-wait-seconds', type=click.INT, help="""The maximum time to wait for the work request to reach the state defined by --wait-for-state. Defaults to 1200 seconds.""")
|
|
804
|
+
@cli_util.option('--wait-interval-seconds', type=click.INT, help="""Check every --wait-interval-seconds to see whether the work request has reached the state defined by --wait-for-state. Defaults to 30 seconds.""")
|
|
637
805
|
@json_skeleton_utils.get_cli_json_input_option({})
|
|
638
806
|
@cli_util.help_option
|
|
639
807
|
@click.pass_context
|
|
640
|
-
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={}
|
|
808
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={})
|
|
641
809
|
@cli_util.wrap_exceptions
|
|
642
|
-
def
|
|
810
|
+
def export_runbook_transfer_runbook_par_url_content_details(ctx, from_json, wait_for_state, max_wait_seconds, wait_interval_seconds, runbook_id, content_destination_url, export_as, if_match):
|
|
643
811
|
|
|
644
|
-
if isinstance(
|
|
645
|
-
raise click.UsageError('Parameter --
|
|
812
|
+
if isinstance(runbook_id, six.string_types) and len(runbook_id.strip()) == 0:
|
|
813
|
+
raise click.UsageError('Parameter --runbook-id cannot be whitespace or empty string')
|
|
646
814
|
|
|
647
815
|
kwargs = {}
|
|
816
|
+
if if_match is not None:
|
|
817
|
+
kwargs['if_match'] = if_match
|
|
648
818
|
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
819
|
+
|
|
820
|
+
_details = {}
|
|
821
|
+
_details['contentDestination'] = {}
|
|
822
|
+
_details['contentDestination']['url'] = content_destination_url
|
|
823
|
+
|
|
824
|
+
if export_as is not None:
|
|
825
|
+
_details['exportAs'] = export_as
|
|
826
|
+
|
|
827
|
+
_details['contentDestination']['sourceType'] = 'PAR_URL'
|
|
828
|
+
|
|
649
829
|
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
650
|
-
result = client.
|
|
651
|
-
|
|
830
|
+
result = client.export_runbook(
|
|
831
|
+
runbook_id=runbook_id,
|
|
832
|
+
export_runbook_details=_details,
|
|
833
|
+
**kwargs
|
|
834
|
+
)
|
|
835
|
+
if wait_for_state:
|
|
836
|
+
|
|
837
|
+
if hasattr(client, 'get_work_request') and callable(getattr(client, 'get_work_request')):
|
|
838
|
+
try:
|
|
839
|
+
wait_period_kwargs = {}
|
|
840
|
+
if max_wait_seconds is not None:
|
|
841
|
+
wait_period_kwargs['max_wait_seconds'] = max_wait_seconds
|
|
842
|
+
if wait_interval_seconds is not None:
|
|
843
|
+
wait_period_kwargs['max_interval_seconds'] = wait_interval_seconds
|
|
844
|
+
if 'opc-work-request-id' not in result.headers:
|
|
845
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state')
|
|
846
|
+
cli_util.render_response(result, ctx)
|
|
847
|
+
return
|
|
848
|
+
|
|
849
|
+
click.echo('Action completed. Waiting until the work request has entered state: {}'.format(wait_for_state), file=sys.stderr)
|
|
850
|
+
result = oci.wait_until(client, client.get_work_request(result.headers['opc-work-request-id']), 'status', wait_for_state, **wait_period_kwargs)
|
|
851
|
+
except oci.exceptions.MaximumWaitTimeExceeded as e:
|
|
852
|
+
# If we fail, we should show an error, but we should still provide the information to the customer
|
|
853
|
+
click.echo('Failed to wait until the work request entered the specified state. Outputting last known resource state', file=sys.stderr)
|
|
854
|
+
cli_util.render_response(result, ctx)
|
|
855
|
+
sys.exit(2)
|
|
856
|
+
except Exception:
|
|
857
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state', file=sys.stderr)
|
|
858
|
+
cli_util.render_response(result, ctx)
|
|
859
|
+
raise
|
|
860
|
+
else:
|
|
861
|
+
click.echo('Unable to wait for the work request to enter the specified state', file=sys.stderr)
|
|
862
|
+
cli_util.render_response(result, ctx)
|
|
863
|
+
|
|
864
|
+
|
|
865
|
+
@runbook_group.command(name=cli_util.override('fleet_apps_management_runbooks.export_runbook_version.command_name', 'export-runbook-version'), help=u"""Export the specified version of the runbook. \n[Command Reference](exportRunbookVersion)""")
|
|
866
|
+
@cli_util.option('--content-destination', required=True, type=custom_types.CLI_COMPLEX_TYPE, help=u"""""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
867
|
+
@cli_util.option('--runbook-version-id', required=True, help=u"""Unique Runbook Version identifier""")
|
|
868
|
+
@cli_util.option('--version-parameterconflict', type=click.FLOAT, help=u"""Export Runbook Version Details.""")
|
|
869
|
+
@cli_util.option('--if-match', help=u"""For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value.""")
|
|
870
|
+
@cli_util.option('--wait-for-state', type=custom_types.CliCaseInsensitiveChoice(["ACCEPTED", "IN_PROGRESS", "WAITING", "NEEDS_ATTENTION", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED"]), multiple=True, help="""This operation asynchronously creates, modifies or deletes a resource and uses a work request to track the progress of the operation. Specify this option to perform the action and then wait until the work request reaches a certain state. Multiple states can be specified, returning on the first state. For example, --wait-for-state SUCCEEDED --wait-for-state FAILED would return on whichever lifecycle state is reached first. If timeout is reached, a return code of 2 is returned. For any other error, a return code of 1 is returned.""")
|
|
871
|
+
@cli_util.option('--max-wait-seconds', type=click.INT, help="""The maximum time to wait for the work request to reach the state defined by --wait-for-state. Defaults to 1200 seconds.""")
|
|
872
|
+
@cli_util.option('--wait-interval-seconds', type=click.INT, help="""Check every --wait-interval-seconds to see whether the work request has reached the state defined by --wait-for-state. Defaults to 30 seconds.""")
|
|
873
|
+
@json_skeleton_utils.get_cli_json_input_option({'content-destination': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}})
|
|
874
|
+
@cli_util.help_option
|
|
875
|
+
@click.pass_context
|
|
876
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={'content-destination': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}})
|
|
877
|
+
@cli_util.wrap_exceptions
|
|
878
|
+
def export_runbook_version(ctx, from_json, wait_for_state, max_wait_seconds, wait_interval_seconds, content_destination, runbook_version_id, version_parameterconflict, if_match):
|
|
879
|
+
|
|
880
|
+
if isinstance(runbook_version_id, six.string_types) and len(runbook_version_id.strip()) == 0:
|
|
881
|
+
raise click.UsageError('Parameter --runbook-version-id cannot be whitespace or empty string')
|
|
882
|
+
|
|
883
|
+
kwargs = {}
|
|
884
|
+
if if_match is not None:
|
|
885
|
+
kwargs['if_match'] = if_match
|
|
886
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
887
|
+
|
|
888
|
+
_details = {}
|
|
889
|
+
_details['contentDestination'] = cli_util.parse_json_parameter("content_destination", content_destination)
|
|
890
|
+
|
|
891
|
+
if version_parameterconflict is not None:
|
|
892
|
+
_details['version'] = version_parameterconflict
|
|
893
|
+
|
|
894
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
895
|
+
result = client.export_runbook_version(
|
|
896
|
+
runbook_version_id=runbook_version_id,
|
|
897
|
+
export_runbook_version_details=_details,
|
|
652
898
|
**kwargs
|
|
653
899
|
)
|
|
900
|
+
if wait_for_state:
|
|
901
|
+
|
|
902
|
+
if hasattr(client, 'get_work_request') and callable(getattr(client, 'get_work_request')):
|
|
903
|
+
try:
|
|
904
|
+
wait_period_kwargs = {}
|
|
905
|
+
if max_wait_seconds is not None:
|
|
906
|
+
wait_period_kwargs['max_wait_seconds'] = max_wait_seconds
|
|
907
|
+
if wait_interval_seconds is not None:
|
|
908
|
+
wait_period_kwargs['max_interval_seconds'] = wait_interval_seconds
|
|
909
|
+
if 'opc-work-request-id' not in result.headers:
|
|
910
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state')
|
|
911
|
+
cli_util.render_response(result, ctx)
|
|
912
|
+
return
|
|
913
|
+
|
|
914
|
+
click.echo('Action completed. Waiting until the work request has entered state: {}'.format(wait_for_state), file=sys.stderr)
|
|
915
|
+
result = oci.wait_until(client, client.get_work_request(result.headers['opc-work-request-id']), 'status', wait_for_state, **wait_period_kwargs)
|
|
916
|
+
except oci.exceptions.MaximumWaitTimeExceeded as e:
|
|
917
|
+
# If we fail, we should show an error, but we should still provide the information to the customer
|
|
918
|
+
click.echo('Failed to wait until the work request entered the specified state. Outputting last known resource state', file=sys.stderr)
|
|
919
|
+
cli_util.render_response(result, ctx)
|
|
920
|
+
sys.exit(2)
|
|
921
|
+
except Exception:
|
|
922
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state', file=sys.stderr)
|
|
923
|
+
cli_util.render_response(result, ctx)
|
|
924
|
+
raise
|
|
925
|
+
else:
|
|
926
|
+
click.echo('Unable to wait for the work request to enter the specified state', file=sys.stderr)
|
|
927
|
+
cli_util.render_response(result, ctx)
|
|
928
|
+
|
|
929
|
+
|
|
930
|
+
@runbook_group.command(name=cli_util.override('fleet_apps_management_runbooks.export_runbook_version_transfer_runbook_object_storage_bucket_content_details.command_name', 'export-runbook-version-transfer-runbook-object-storage-bucket-content-details'), help=u"""Export the specified version of the runbook. \n[Command Reference](exportRunbookVersion)""")
|
|
931
|
+
@cli_util.option('--runbook-version-id', required=True, help=u"""Unique Runbook Version identifier""")
|
|
932
|
+
@cli_util.option('--content-destination-namespace-name', required=True, help=u"""Namespace.""")
|
|
933
|
+
@cli_util.option('--content-destination-bucket-name', required=True, help=u"""Bucket Name.""")
|
|
934
|
+
@cli_util.option('--version-parameterconflict', type=click.FLOAT, help=u"""Export Runbook Version Details.""")
|
|
935
|
+
@cli_util.option('--if-match', help=u"""For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value.""")
|
|
936
|
+
@cli_util.option('--content-destination-object-name', help=u"""Object Name.""")
|
|
937
|
+
@cli_util.option('--content-destination-checksum', help=u"""md5 checksum of the artifact.""")
|
|
938
|
+
@cli_util.option('--wait-for-state', type=custom_types.CliCaseInsensitiveChoice(["ACCEPTED", "IN_PROGRESS", "WAITING", "NEEDS_ATTENTION", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED"]), multiple=True, help="""This operation asynchronously creates, modifies or deletes a resource and uses a work request to track the progress of the operation. Specify this option to perform the action and then wait until the work request reaches a certain state. Multiple states can be specified, returning on the first state. For example, --wait-for-state SUCCEEDED --wait-for-state FAILED would return on whichever lifecycle state is reached first. If timeout is reached, a return code of 2 is returned. For any other error, a return code of 1 is returned.""")
|
|
939
|
+
@cli_util.option('--max-wait-seconds', type=click.INT, help="""The maximum time to wait for the work request to reach the state defined by --wait-for-state. Defaults to 1200 seconds.""")
|
|
940
|
+
@cli_util.option('--wait-interval-seconds', type=click.INT, help="""Check every --wait-interval-seconds to see whether the work request has reached the state defined by --wait-for-state. Defaults to 30 seconds.""")
|
|
941
|
+
@json_skeleton_utils.get_cli_json_input_option({})
|
|
942
|
+
@cli_util.help_option
|
|
943
|
+
@click.pass_context
|
|
944
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={})
|
|
945
|
+
@cli_util.wrap_exceptions
|
|
946
|
+
def export_runbook_version_transfer_runbook_object_storage_bucket_content_details(ctx, from_json, wait_for_state, max_wait_seconds, wait_interval_seconds, runbook_version_id, content_destination_namespace_name, content_destination_bucket_name, version_parameterconflict, if_match, content_destination_object_name, content_destination_checksum):
|
|
947
|
+
|
|
948
|
+
if isinstance(runbook_version_id, six.string_types) and len(runbook_version_id.strip()) == 0:
|
|
949
|
+
raise click.UsageError('Parameter --runbook-version-id cannot be whitespace or empty string')
|
|
950
|
+
|
|
951
|
+
kwargs = {}
|
|
952
|
+
if if_match is not None:
|
|
953
|
+
kwargs['if_match'] = if_match
|
|
954
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
955
|
+
|
|
956
|
+
_details = {}
|
|
957
|
+
_details['contentDestination'] = {}
|
|
958
|
+
_details['contentDestination']['namespaceName'] = content_destination_namespace_name
|
|
959
|
+
_details['contentDestination']['bucketName'] = content_destination_bucket_name
|
|
960
|
+
|
|
961
|
+
if version_parameterconflict is not None:
|
|
962
|
+
_details['version'] = version_parameterconflict
|
|
963
|
+
|
|
964
|
+
if content_destination_object_name is not None:
|
|
965
|
+
_details['contentDestination']['objectName'] = content_destination_object_name
|
|
966
|
+
|
|
967
|
+
if content_destination_checksum is not None:
|
|
968
|
+
_details['contentDestination']['checksum'] = content_destination_checksum
|
|
969
|
+
|
|
970
|
+
_details['contentDestination']['sourceType'] = 'OBJECT_STORAGE_BUCKET'
|
|
971
|
+
|
|
972
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
973
|
+
result = client.export_runbook_version(
|
|
974
|
+
runbook_version_id=runbook_version_id,
|
|
975
|
+
export_runbook_version_details=_details,
|
|
976
|
+
**kwargs
|
|
977
|
+
)
|
|
978
|
+
if wait_for_state:
|
|
979
|
+
|
|
980
|
+
if hasattr(client, 'get_work_request') and callable(getattr(client, 'get_work_request')):
|
|
981
|
+
try:
|
|
982
|
+
wait_period_kwargs = {}
|
|
983
|
+
if max_wait_seconds is not None:
|
|
984
|
+
wait_period_kwargs['max_wait_seconds'] = max_wait_seconds
|
|
985
|
+
if wait_interval_seconds is not None:
|
|
986
|
+
wait_period_kwargs['max_interval_seconds'] = wait_interval_seconds
|
|
987
|
+
if 'opc-work-request-id' not in result.headers:
|
|
988
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state')
|
|
989
|
+
cli_util.render_response(result, ctx)
|
|
990
|
+
return
|
|
991
|
+
|
|
992
|
+
click.echo('Action completed. Waiting until the work request has entered state: {}'.format(wait_for_state), file=sys.stderr)
|
|
993
|
+
result = oci.wait_until(client, client.get_work_request(result.headers['opc-work-request-id']), 'status', wait_for_state, **wait_period_kwargs)
|
|
994
|
+
except oci.exceptions.MaximumWaitTimeExceeded as e:
|
|
995
|
+
# If we fail, we should show an error, but we should still provide the information to the customer
|
|
996
|
+
click.echo('Failed to wait until the work request entered the specified state. Outputting last known resource state', file=sys.stderr)
|
|
997
|
+
cli_util.render_response(result, ctx)
|
|
998
|
+
sys.exit(2)
|
|
999
|
+
except Exception:
|
|
1000
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state', file=sys.stderr)
|
|
1001
|
+
cli_util.render_response(result, ctx)
|
|
1002
|
+
raise
|
|
1003
|
+
else:
|
|
1004
|
+
click.echo('Unable to wait for the work request to enter the specified state', file=sys.stderr)
|
|
1005
|
+
cli_util.render_response(result, ctx)
|
|
1006
|
+
|
|
1007
|
+
|
|
1008
|
+
@runbook_group.command(name=cli_util.override('fleet_apps_management_runbooks.export_runbook_version_transfer_runbook_par_url_content_details.command_name', 'export-runbook-version-transfer-runbook-par-url-content-details'), help=u"""Export the specified version of the runbook. \n[Command Reference](exportRunbookVersion)""")
|
|
1009
|
+
@cli_util.option('--runbook-version-id', required=True, help=u"""Unique Runbook Version identifier""")
|
|
1010
|
+
@cli_util.option('--content-destination-url', required=True, help=u"""PAR url.""")
|
|
1011
|
+
@cli_util.option('--version-parameterconflict', type=click.FLOAT, help=u"""Export Runbook Version Details.""")
|
|
1012
|
+
@cli_util.option('--if-match', help=u"""For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value.""")
|
|
1013
|
+
@cli_util.option('--wait-for-state', type=custom_types.CliCaseInsensitiveChoice(["ACCEPTED", "IN_PROGRESS", "WAITING", "NEEDS_ATTENTION", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED"]), multiple=True, help="""This operation asynchronously creates, modifies or deletes a resource and uses a work request to track the progress of the operation. Specify this option to perform the action and then wait until the work request reaches a certain state. Multiple states can be specified, returning on the first state. For example, --wait-for-state SUCCEEDED --wait-for-state FAILED would return on whichever lifecycle state is reached first. If timeout is reached, a return code of 2 is returned. For any other error, a return code of 1 is returned.""")
|
|
1014
|
+
@cli_util.option('--max-wait-seconds', type=click.INT, help="""The maximum time to wait for the work request to reach the state defined by --wait-for-state. Defaults to 1200 seconds.""")
|
|
1015
|
+
@cli_util.option('--wait-interval-seconds', type=click.INT, help="""Check every --wait-interval-seconds to see whether the work request has reached the state defined by --wait-for-state. Defaults to 30 seconds.""")
|
|
1016
|
+
@json_skeleton_utils.get_cli_json_input_option({})
|
|
1017
|
+
@cli_util.help_option
|
|
1018
|
+
@click.pass_context
|
|
1019
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={})
|
|
1020
|
+
@cli_util.wrap_exceptions
|
|
1021
|
+
def export_runbook_version_transfer_runbook_par_url_content_details(ctx, from_json, wait_for_state, max_wait_seconds, wait_interval_seconds, runbook_version_id, content_destination_url, version_parameterconflict, if_match):
|
|
1022
|
+
|
|
1023
|
+
if isinstance(runbook_version_id, six.string_types) and len(runbook_version_id.strip()) == 0:
|
|
1024
|
+
raise click.UsageError('Parameter --runbook-version-id cannot be whitespace or empty string')
|
|
1025
|
+
|
|
1026
|
+
kwargs = {}
|
|
1027
|
+
if if_match is not None:
|
|
1028
|
+
kwargs['if_match'] = if_match
|
|
1029
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
1030
|
+
|
|
1031
|
+
_details = {}
|
|
1032
|
+
_details['contentDestination'] = {}
|
|
1033
|
+
_details['contentDestination']['url'] = content_destination_url
|
|
1034
|
+
|
|
1035
|
+
if version_parameterconflict is not None:
|
|
1036
|
+
_details['version'] = version_parameterconflict
|
|
1037
|
+
|
|
1038
|
+
_details['contentDestination']['sourceType'] = 'PAR_URL'
|
|
1039
|
+
|
|
1040
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
1041
|
+
result = client.export_runbook_version(
|
|
1042
|
+
runbook_version_id=runbook_version_id,
|
|
1043
|
+
export_runbook_version_details=_details,
|
|
1044
|
+
**kwargs
|
|
1045
|
+
)
|
|
1046
|
+
if wait_for_state:
|
|
1047
|
+
|
|
1048
|
+
if hasattr(client, 'get_work_request') and callable(getattr(client, 'get_work_request')):
|
|
1049
|
+
try:
|
|
1050
|
+
wait_period_kwargs = {}
|
|
1051
|
+
if max_wait_seconds is not None:
|
|
1052
|
+
wait_period_kwargs['max_wait_seconds'] = max_wait_seconds
|
|
1053
|
+
if wait_interval_seconds is not None:
|
|
1054
|
+
wait_period_kwargs['max_interval_seconds'] = wait_interval_seconds
|
|
1055
|
+
if 'opc-work-request-id' not in result.headers:
|
|
1056
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state')
|
|
1057
|
+
cli_util.render_response(result, ctx)
|
|
1058
|
+
return
|
|
1059
|
+
|
|
1060
|
+
click.echo('Action completed. Waiting until the work request has entered state: {}'.format(wait_for_state), file=sys.stderr)
|
|
1061
|
+
result = oci.wait_until(client, client.get_work_request(result.headers['opc-work-request-id']), 'status', wait_for_state, **wait_period_kwargs)
|
|
1062
|
+
except oci.exceptions.MaximumWaitTimeExceeded as e:
|
|
1063
|
+
# If we fail, we should show an error, but we should still provide the information to the customer
|
|
1064
|
+
click.echo('Failed to wait until the work request entered the specified state. Outputting last known resource state', file=sys.stderr)
|
|
1065
|
+
cli_util.render_response(result, ctx)
|
|
1066
|
+
sys.exit(2)
|
|
1067
|
+
except Exception:
|
|
1068
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state', file=sys.stderr)
|
|
1069
|
+
cli_util.render_response(result, ctx)
|
|
1070
|
+
raise
|
|
1071
|
+
else:
|
|
1072
|
+
click.echo('Unable to wait for the work request to enter the specified state', file=sys.stderr)
|
|
1073
|
+
cli_util.render_response(result, ctx)
|
|
1074
|
+
|
|
1075
|
+
|
|
1076
|
+
@runbook_export_dependency_collection_group.command(name=cli_util.override('fleet_apps_management_runbooks.find_runbook_export_dependency.command_name', 'find-runbook-export-dependency'), help=u"""Find runbook export Dependencies \n[Command Reference](findRunbookExportDependency)""")
|
|
1077
|
+
@cli_util.option('--runbook-id', required=True, help=u"""The OCID of the resource.""")
|
|
1078
|
+
@cli_util.option('--runbook-version-id', help=u"""The OCID of the resource.""")
|
|
1079
|
+
@cli_util.option('--limit', type=click.INT, help=u"""The maximum number of items to return.""")
|
|
1080
|
+
@cli_util.option('--page', help=u"""A token representing the position at which to start retrieving results. This must come from the `opc-next-page` header field of a previous response.""")
|
|
1081
|
+
@json_skeleton_utils.get_cli_json_input_option({})
|
|
1082
|
+
@cli_util.help_option
|
|
1083
|
+
@click.pass_context
|
|
1084
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={}, output_type={'module': 'fleet_apps_management', 'class': 'RunbookExportDependencyCollection'})
|
|
1085
|
+
@cli_util.wrap_exceptions
|
|
1086
|
+
def find_runbook_export_dependency(ctx, from_json, runbook_id, runbook_version_id, limit, page):
|
|
1087
|
+
|
|
1088
|
+
kwargs = {}
|
|
1089
|
+
if limit is not None:
|
|
1090
|
+
kwargs['limit'] = limit
|
|
1091
|
+
if page is not None:
|
|
1092
|
+
kwargs['page'] = page
|
|
1093
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
1094
|
+
|
|
1095
|
+
_details = {}
|
|
1096
|
+
_details['runbookId'] = runbook_id
|
|
1097
|
+
|
|
1098
|
+
if runbook_version_id is not None:
|
|
1099
|
+
_details['runbookVersionId'] = runbook_version_id
|
|
1100
|
+
|
|
1101
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
1102
|
+
result = client.find_runbook_export_dependency(
|
|
1103
|
+
find_runbook_export_dependency_details=_details,
|
|
1104
|
+
**kwargs
|
|
1105
|
+
)
|
|
1106
|
+
cli_util.render_response(result, ctx)
|
|
1107
|
+
|
|
1108
|
+
|
|
1109
|
+
@runbook_import_dependency_collection_group.command(name=cli_util.override('fleet_apps_management_runbooks.find_runbook_import_dependency.command_name', 'find-runbook-import-dependency'), help=u"""Find runbook import Dependencies \n[Command Reference](findRunbookImportDependency)""")
|
|
1110
|
+
@cli_util.option('--compartment-id', required=True, help=u"""OCID of the compartment to which the resource belongs to.""")
|
|
1111
|
+
@cli_util.option('--content', required=True, type=custom_types.CLI_COMPLEX_TYPE, help=u"""""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
1112
|
+
@cli_util.option('--limit', type=click.INT, help=u"""The maximum number of items to return.""")
|
|
1113
|
+
@cli_util.option('--page', help=u"""A token representing the position at which to start retrieving results. This must come from the `opc-next-page` header field of a previous response.""")
|
|
1114
|
+
@json_skeleton_utils.get_cli_json_input_option({'content': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}})
|
|
1115
|
+
@cli_util.help_option
|
|
1116
|
+
@click.pass_context
|
|
1117
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={'content': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}}, output_type={'module': 'fleet_apps_management', 'class': 'RunbookImportDependencyCollection'})
|
|
1118
|
+
@cli_util.wrap_exceptions
|
|
1119
|
+
def find_runbook_import_dependency(ctx, from_json, compartment_id, content, limit, page):
|
|
1120
|
+
|
|
1121
|
+
kwargs = {}
|
|
1122
|
+
if limit is not None:
|
|
1123
|
+
kwargs['limit'] = limit
|
|
1124
|
+
if page is not None:
|
|
1125
|
+
kwargs['page'] = page
|
|
1126
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
1127
|
+
|
|
1128
|
+
_details = {}
|
|
1129
|
+
_details['compartmentId'] = compartment_id
|
|
1130
|
+
_details['content'] = cli_util.parse_json_parameter("content", content)
|
|
1131
|
+
|
|
1132
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
1133
|
+
result = client.find_runbook_import_dependency(
|
|
1134
|
+
find_runbook_import_dependency_details=_details,
|
|
1135
|
+
**kwargs
|
|
1136
|
+
)
|
|
1137
|
+
cli_util.render_response(result, ctx)
|
|
1138
|
+
|
|
1139
|
+
|
|
1140
|
+
@runbook_import_dependency_collection_group.command(name=cli_util.override('fleet_apps_management_runbooks.find_runbook_import_dependency_transfer_runbook_object_storage_bucket_content_details.command_name', 'find-runbook-import-dependency-transfer-runbook-object-storage-bucket-content-details'), help=u"""Find runbook import Dependencies \n[Command Reference](findRunbookImportDependency)""")
|
|
1141
|
+
@cli_util.option('--compartment-id', required=True, help=u"""OCID of the compartment to which the resource belongs to.""")
|
|
1142
|
+
@cli_util.option('--content-namespace-name', required=True, help=u"""Namespace.""")
|
|
1143
|
+
@cli_util.option('--content-bucket-name', required=True, help=u"""Bucket Name.""")
|
|
1144
|
+
@cli_util.option('--limit', type=click.INT, help=u"""The maximum number of items to return.""")
|
|
1145
|
+
@cli_util.option('--page', help=u"""A token representing the position at which to start retrieving results. This must come from the `opc-next-page` header field of a previous response.""")
|
|
1146
|
+
@cli_util.option('--content-object-name', help=u"""Object Name.""")
|
|
1147
|
+
@cli_util.option('--content-checksum', help=u"""md5 checksum of the artifact.""")
|
|
1148
|
+
@json_skeleton_utils.get_cli_json_input_option({})
|
|
1149
|
+
@cli_util.help_option
|
|
1150
|
+
@click.pass_context
|
|
1151
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={}, output_type={'module': 'fleet_apps_management', 'class': 'RunbookImportDependencyCollection'})
|
|
1152
|
+
@cli_util.wrap_exceptions
|
|
1153
|
+
def find_runbook_import_dependency_transfer_runbook_object_storage_bucket_content_details(ctx, from_json, compartment_id, content_namespace_name, content_bucket_name, limit, page, content_object_name, content_checksum):
|
|
1154
|
+
|
|
1155
|
+
kwargs = {}
|
|
1156
|
+
if limit is not None:
|
|
1157
|
+
kwargs['limit'] = limit
|
|
1158
|
+
if page is not None:
|
|
1159
|
+
kwargs['page'] = page
|
|
1160
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
1161
|
+
|
|
1162
|
+
_details = {}
|
|
1163
|
+
_details['content'] = {}
|
|
1164
|
+
_details['compartmentId'] = compartment_id
|
|
1165
|
+
_details['content']['namespaceName'] = content_namespace_name
|
|
1166
|
+
_details['content']['bucketName'] = content_bucket_name
|
|
1167
|
+
|
|
1168
|
+
if content_object_name is not None:
|
|
1169
|
+
_details['content']['objectName'] = content_object_name
|
|
1170
|
+
|
|
1171
|
+
if content_checksum is not None:
|
|
1172
|
+
_details['content']['checksum'] = content_checksum
|
|
1173
|
+
|
|
1174
|
+
_details['content']['sourceType'] = 'OBJECT_STORAGE_BUCKET'
|
|
1175
|
+
|
|
1176
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
1177
|
+
result = client.find_runbook_import_dependency(
|
|
1178
|
+
find_runbook_import_dependency_details=_details,
|
|
1179
|
+
**kwargs
|
|
1180
|
+
)
|
|
1181
|
+
cli_util.render_response(result, ctx)
|
|
1182
|
+
|
|
1183
|
+
|
|
1184
|
+
@runbook_import_dependency_collection_group.command(name=cli_util.override('fleet_apps_management_runbooks.find_runbook_import_dependency_transfer_runbook_par_url_content_details.command_name', 'find-runbook-import-dependency-transfer-runbook-par-url-content-details'), help=u"""Find runbook import Dependencies \n[Command Reference](findRunbookImportDependency)""")
|
|
1185
|
+
@cli_util.option('--compartment-id', required=True, help=u"""OCID of the compartment to which the resource belongs to.""")
|
|
1186
|
+
@cli_util.option('--content-url', required=True, help=u"""PAR url.""")
|
|
1187
|
+
@cli_util.option('--limit', type=click.INT, help=u"""The maximum number of items to return.""")
|
|
1188
|
+
@cli_util.option('--page', help=u"""A token representing the position at which to start retrieving results. This must come from the `opc-next-page` header field of a previous response.""")
|
|
1189
|
+
@json_skeleton_utils.get_cli_json_input_option({})
|
|
1190
|
+
@cli_util.help_option
|
|
1191
|
+
@click.pass_context
|
|
1192
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={}, output_type={'module': 'fleet_apps_management', 'class': 'RunbookImportDependencyCollection'})
|
|
1193
|
+
@cli_util.wrap_exceptions
|
|
1194
|
+
def find_runbook_import_dependency_transfer_runbook_par_url_content_details(ctx, from_json, compartment_id, content_url, limit, page):
|
|
1195
|
+
|
|
1196
|
+
kwargs = {}
|
|
1197
|
+
if limit is not None:
|
|
1198
|
+
kwargs['limit'] = limit
|
|
1199
|
+
if page is not None:
|
|
1200
|
+
kwargs['page'] = page
|
|
1201
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
1202
|
+
|
|
1203
|
+
_details = {}
|
|
1204
|
+
_details['content'] = {}
|
|
1205
|
+
_details['compartmentId'] = compartment_id
|
|
1206
|
+
_details['content']['url'] = content_url
|
|
1207
|
+
|
|
1208
|
+
_details['content']['sourceType'] = 'PAR_URL'
|
|
1209
|
+
|
|
1210
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
1211
|
+
result = client.find_runbook_import_dependency(
|
|
1212
|
+
find_runbook_import_dependency_details=_details,
|
|
1213
|
+
**kwargs
|
|
1214
|
+
)
|
|
1215
|
+
cli_util.render_response(result, ctx)
|
|
1216
|
+
|
|
1217
|
+
|
|
1218
|
+
@runbook_group.command(name=cli_util.override('fleet_apps_management_runbooks.get_runbook.command_name', 'get'), help=u"""Get the details of a runbook in Fleet Application Management. \n[Command Reference](getRunbook)""")
|
|
1219
|
+
@cli_util.option('--runbook-id', required=True, help=u"""Unique Runbook identifier""")
|
|
1220
|
+
@json_skeleton_utils.get_cli_json_input_option({})
|
|
1221
|
+
@cli_util.help_option
|
|
1222
|
+
@click.pass_context
|
|
1223
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={}, output_type={'module': 'fleet_apps_management', 'class': 'Runbook'})
|
|
1224
|
+
@cli_util.wrap_exceptions
|
|
1225
|
+
def get_runbook(ctx, from_json, runbook_id):
|
|
1226
|
+
|
|
1227
|
+
if isinstance(runbook_id, six.string_types) and len(runbook_id.strip()) == 0:
|
|
1228
|
+
raise click.UsageError('Parameter --runbook-id cannot be whitespace or empty string')
|
|
1229
|
+
|
|
1230
|
+
kwargs = {}
|
|
1231
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
1232
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
1233
|
+
result = client.get_runbook(
|
|
1234
|
+
runbook_id=runbook_id,
|
|
1235
|
+
**kwargs
|
|
1236
|
+
)
|
|
1237
|
+
cli_util.render_response(result, ctx)
|
|
1238
|
+
|
|
1239
|
+
|
|
1240
|
+
@runbook_export_group.command(name=cli_util.override('fleet_apps_management_runbooks.get_runbook_export.command_name', 'get'), help=u"""Get the runbook export status for provided runbook and exportId. \n[Command Reference](getRunbookExport)""")
|
|
1241
|
+
@cli_util.option('--runbook-id', required=True, help=u"""Unique Runbook identifier""")
|
|
1242
|
+
@cli_util.option('--export-id', required=True, help=u"""Unique tracking identifier to fetch runbook export status""")
|
|
1243
|
+
@json_skeleton_utils.get_cli_json_input_option({})
|
|
1244
|
+
@cli_util.help_option
|
|
1245
|
+
@click.pass_context
|
|
1246
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={}, output_type={'module': 'fleet_apps_management', 'class': 'RunbookExport'})
|
|
1247
|
+
@cli_util.wrap_exceptions
|
|
1248
|
+
def get_runbook_export(ctx, from_json, runbook_id, export_id):
|
|
1249
|
+
|
|
1250
|
+
if isinstance(runbook_id, six.string_types) and len(runbook_id.strip()) == 0:
|
|
1251
|
+
raise click.UsageError('Parameter --runbook-id cannot be whitespace or empty string')
|
|
1252
|
+
|
|
1253
|
+
if isinstance(export_id, six.string_types) and len(export_id.strip()) == 0:
|
|
1254
|
+
raise click.UsageError('Parameter --export-id cannot be whitespace or empty string')
|
|
1255
|
+
|
|
1256
|
+
kwargs = {}
|
|
1257
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
1258
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
1259
|
+
result = client.get_runbook_export(
|
|
1260
|
+
runbook_id=runbook_id,
|
|
1261
|
+
export_id=export_id,
|
|
1262
|
+
**kwargs
|
|
1263
|
+
)
|
|
1264
|
+
cli_util.render_response(result, ctx)
|
|
1265
|
+
|
|
1266
|
+
|
|
1267
|
+
@runbook_import_group.command(name=cli_util.override('fleet_apps_management_runbooks.get_runbook_import.command_name', 'get'), help=u"""Get the runbook import status for provided runbook and importId. \n[Command Reference](getRunbookImport)""")
|
|
1268
|
+
@cli_util.option('--runbook-id', required=True, help=u"""Unique Runbook identifier""")
|
|
1269
|
+
@cli_util.option('--import-id', required=True, help=u"""Unique tracking identifier to fetch runbook import status""")
|
|
1270
|
+
@json_skeleton_utils.get_cli_json_input_option({})
|
|
1271
|
+
@cli_util.help_option
|
|
1272
|
+
@click.pass_context
|
|
1273
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={}, output_type={'module': 'fleet_apps_management', 'class': 'RunbookImport'})
|
|
1274
|
+
@cli_util.wrap_exceptions
|
|
1275
|
+
def get_runbook_import(ctx, from_json, runbook_id, import_id):
|
|
1276
|
+
|
|
1277
|
+
if isinstance(runbook_id, six.string_types) and len(runbook_id.strip()) == 0:
|
|
1278
|
+
raise click.UsageError('Parameter --runbook-id cannot be whitespace or empty string')
|
|
1279
|
+
|
|
1280
|
+
if isinstance(import_id, six.string_types) and len(import_id.strip()) == 0:
|
|
1281
|
+
raise click.UsageError('Parameter --import-id cannot be whitespace or empty string')
|
|
1282
|
+
|
|
1283
|
+
kwargs = {}
|
|
1284
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
1285
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
1286
|
+
result = client.get_runbook_import(
|
|
1287
|
+
runbook_id=runbook_id,
|
|
1288
|
+
import_id=import_id,
|
|
1289
|
+
**kwargs
|
|
1290
|
+
)
|
|
1291
|
+
cli_util.render_response(result, ctx)
|
|
1292
|
+
|
|
1293
|
+
|
|
1294
|
+
@runbook_version_group.command(name=cli_util.override('fleet_apps_management_runbooks.get_runbook_version.command_name', 'get'), help=u"""Gets a Runbook Version by identifier. \n[Command Reference](getRunbookVersion)""")
|
|
1295
|
+
@cli_util.option('--runbook-version-id', required=True, help=u"""Unique Runbook Version identifier""")
|
|
1296
|
+
@json_skeleton_utils.get_cli_json_input_option({})
|
|
1297
|
+
@cli_util.help_option
|
|
1298
|
+
@click.pass_context
|
|
1299
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={}, output_type={'module': 'fleet_apps_management', 'class': 'RunbookVersion'})
|
|
1300
|
+
@cli_util.wrap_exceptions
|
|
1301
|
+
def get_runbook_version(ctx, from_json, runbook_version_id):
|
|
1302
|
+
|
|
1303
|
+
if isinstance(runbook_version_id, six.string_types) and len(runbook_version_id.strip()) == 0:
|
|
1304
|
+
raise click.UsageError('Parameter --runbook-version-id cannot be whitespace or empty string')
|
|
1305
|
+
|
|
1306
|
+
kwargs = {}
|
|
1307
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
1308
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
1309
|
+
result = client.get_runbook_version(
|
|
1310
|
+
runbook_version_id=runbook_version_id,
|
|
1311
|
+
**kwargs
|
|
1312
|
+
)
|
|
1313
|
+
cli_util.render_response(result, ctx)
|
|
1314
|
+
|
|
1315
|
+
|
|
1316
|
+
@task_record_group.command(name=cli_util.override('fleet_apps_management_runbooks.get_task_record.command_name', 'get'), help=u"""Gets information for the specified task record. \n[Command Reference](getTaskRecord)""")
|
|
1317
|
+
@cli_util.option('--task-record-id', required=True, help=u"""The OCID of the task record.""")
|
|
1318
|
+
@json_skeleton_utils.get_cli_json_input_option({})
|
|
1319
|
+
@cli_util.help_option
|
|
1320
|
+
@click.pass_context
|
|
1321
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={}, output_type={'module': 'fleet_apps_management', 'class': 'TaskRecord'})
|
|
1322
|
+
@cli_util.wrap_exceptions
|
|
1323
|
+
def get_task_record(ctx, from_json, task_record_id):
|
|
1324
|
+
|
|
1325
|
+
if isinstance(task_record_id, six.string_types) and len(task_record_id.strip()) == 0:
|
|
1326
|
+
raise click.UsageError('Parameter --task-record-id cannot be whitespace or empty string')
|
|
1327
|
+
|
|
1328
|
+
kwargs = {}
|
|
1329
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
1330
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
1331
|
+
result = client.get_task_record(
|
|
1332
|
+
task_record_id=task_record_id,
|
|
1333
|
+
**kwargs
|
|
1334
|
+
)
|
|
1335
|
+
cli_util.render_response(result, ctx)
|
|
1336
|
+
|
|
1337
|
+
|
|
1338
|
+
@import_runbook_details_group.command(name=cli_util.override('fleet_apps_management_runbooks.import_runbook.command_name', 'import-runbook'), help=u"""Import the specified version of the runbook. \n[Command Reference](importRunbook)""")
|
|
1339
|
+
@cli_util.option('--compartment-id', required=True, help=u"""OCID of the compartment to which the resource belongs to.""")
|
|
1340
|
+
@cli_util.option('--content-source', required=True, type=custom_types.CLI_COMPLEX_TYPE, help=u"""""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
1341
|
+
@cli_util.option('--content-destination', required=True, type=custom_types.CLI_COMPLEX_TYPE, help=u"""""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
1342
|
+
@cli_util.option('--runbook-name', help=u"""The name of the runbook.""")
|
|
1343
|
+
@cli_util.option('--import-option', type=custom_types.CliCaseInsensitiveChoice(["RETAIN", "REPLACE", "INCREMENT"]), help=u"""ImportOptions for Runbook.""")
|
|
1344
|
+
@cli_util.option('--version-parameterconflict', help=u"""Version number.""")
|
|
1345
|
+
@cli_util.option('--required-values', type=custom_types.CLI_COMPLEX_TYPE, help=u"""List of required values.
|
|
1346
|
+
|
|
1347
|
+
This option is a JSON list with items of type RunbookImportRequiredValue. For documentation on RunbookImportRequiredValue please see our API reference: https://docs.cloud.oracle.com/api/#/en/fleetappsmanagementrunbooks/20250228/datatypes/RunbookImportRequiredValue.""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
1348
|
+
@cli_util.option('--if-match', help=u"""For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value.""")
|
|
1349
|
+
@cli_util.option('--wait-for-state', type=custom_types.CliCaseInsensitiveChoice(["ACCEPTED", "IN_PROGRESS", "WAITING", "NEEDS_ATTENTION", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED"]), multiple=True, help="""This operation asynchronously creates, modifies or deletes a resource and uses a work request to track the progress of the operation. Specify this option to perform the action and then wait until the work request reaches a certain state. Multiple states can be specified, returning on the first state. For example, --wait-for-state SUCCEEDED --wait-for-state FAILED would return on whichever lifecycle state is reached first. If timeout is reached, a return code of 2 is returned. For any other error, a return code of 1 is returned.""")
|
|
1350
|
+
@cli_util.option('--max-wait-seconds', type=click.INT, help="""The maximum time to wait for the work request to reach the state defined by --wait-for-state. Defaults to 1200 seconds.""")
|
|
1351
|
+
@cli_util.option('--wait-interval-seconds', type=click.INT, help="""Check every --wait-interval-seconds to see whether the work request has reached the state defined by --wait-for-state. Defaults to 30 seconds.""")
|
|
1352
|
+
@json_skeleton_utils.get_cli_json_input_option({'content-source': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}, 'content-destination': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}, 'required-values': {'module': 'fleet_apps_management', 'class': 'list[RunbookImportRequiredValue]'}})
|
|
1353
|
+
@cli_util.help_option
|
|
1354
|
+
@click.pass_context
|
|
1355
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={'content-source': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}, 'content-destination': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}, 'required-values': {'module': 'fleet_apps_management', 'class': 'list[RunbookImportRequiredValue]'}})
|
|
1356
|
+
@cli_util.wrap_exceptions
|
|
1357
|
+
def import_runbook(ctx, from_json, wait_for_state, max_wait_seconds, wait_interval_seconds, compartment_id, content_source, content_destination, runbook_name, import_option, version_parameterconflict, required_values, if_match):
|
|
1358
|
+
|
|
1359
|
+
kwargs = {}
|
|
1360
|
+
if if_match is not None:
|
|
1361
|
+
kwargs['if_match'] = if_match
|
|
1362
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
1363
|
+
|
|
1364
|
+
_details = {}
|
|
1365
|
+
_details['compartmentId'] = compartment_id
|
|
1366
|
+
_details['contentSource'] = cli_util.parse_json_parameter("content_source", content_source)
|
|
1367
|
+
_details['contentDestination'] = cli_util.parse_json_parameter("content_destination", content_destination)
|
|
1368
|
+
|
|
1369
|
+
if runbook_name is not None:
|
|
1370
|
+
_details['runbookName'] = runbook_name
|
|
1371
|
+
|
|
1372
|
+
if import_option is not None:
|
|
1373
|
+
_details['importOption'] = import_option
|
|
1374
|
+
|
|
1375
|
+
if version_parameterconflict is not None:
|
|
1376
|
+
_details['version'] = version_parameterconflict
|
|
1377
|
+
|
|
1378
|
+
if required_values is not None:
|
|
1379
|
+
_details['requiredValues'] = cli_util.parse_json_parameter("required_values", required_values)
|
|
1380
|
+
|
|
1381
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
1382
|
+
result = client.import_runbook(
|
|
1383
|
+
import_runbook_details=_details,
|
|
1384
|
+
**kwargs
|
|
1385
|
+
)
|
|
1386
|
+
if wait_for_state:
|
|
1387
|
+
|
|
1388
|
+
if hasattr(client, 'get_work_request') and callable(getattr(client, 'get_work_request')):
|
|
1389
|
+
try:
|
|
1390
|
+
wait_period_kwargs = {}
|
|
1391
|
+
if max_wait_seconds is not None:
|
|
1392
|
+
wait_period_kwargs['max_wait_seconds'] = max_wait_seconds
|
|
1393
|
+
if wait_interval_seconds is not None:
|
|
1394
|
+
wait_period_kwargs['max_interval_seconds'] = wait_interval_seconds
|
|
1395
|
+
if 'opc-work-request-id' not in result.headers:
|
|
1396
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state')
|
|
1397
|
+
cli_util.render_response(result, ctx)
|
|
1398
|
+
return
|
|
1399
|
+
|
|
1400
|
+
click.echo('Action completed. Waiting until the work request has entered state: {}'.format(wait_for_state), file=sys.stderr)
|
|
1401
|
+
result = oci.wait_until(client, client.get_work_request(result.headers['opc-work-request-id']), 'status', wait_for_state, **wait_period_kwargs)
|
|
1402
|
+
except oci.exceptions.MaximumWaitTimeExceeded as e:
|
|
1403
|
+
# If we fail, we should show an error, but we should still provide the information to the customer
|
|
1404
|
+
click.echo('Failed to wait until the work request entered the specified state. Outputting last known resource state', file=sys.stderr)
|
|
1405
|
+
cli_util.render_response(result, ctx)
|
|
1406
|
+
sys.exit(2)
|
|
1407
|
+
except Exception:
|
|
1408
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state', file=sys.stderr)
|
|
1409
|
+
cli_util.render_response(result, ctx)
|
|
1410
|
+
raise
|
|
1411
|
+
else:
|
|
1412
|
+
click.echo('Unable to wait for the work request to enter the specified state', file=sys.stderr)
|
|
1413
|
+
cli_util.render_response(result, ctx)
|
|
1414
|
+
|
|
1415
|
+
|
|
1416
|
+
@import_runbook_precheck_details_group.command(name=cli_util.override('fleet_apps_management_runbooks.import_runbook_precheck.command_name', 'import-runbook-precheck'), help=u"""Precheck for import runbook. \n[Command Reference](importRunbookPrecheck)""")
|
|
1417
|
+
@cli_util.option('--compartment-id', required=True, help=u"""OCID of the compartment to which the resource belongs to.""")
|
|
1418
|
+
@cli_util.option('--content-source', required=True, type=custom_types.CLI_COMPLEX_TYPE, help=u"""""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
1419
|
+
@cli_util.option('--content-destination', required=True, type=custom_types.CLI_COMPLEX_TYPE, help=u"""""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
1420
|
+
@cli_util.option('--import-as', type=custom_types.CLI_COMPLEX_TYPE, help=u"""""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
1421
|
+
@cli_util.option('--required-values', type=custom_types.CLI_COMPLEX_TYPE, help=u"""List of required values.
|
|
1422
|
+
|
|
1423
|
+
This option is a JSON list with items of type ImportRunbookPrecheckRequiredValue. For documentation on ImportRunbookPrecheckRequiredValue please see our API reference: https://docs.cloud.oracle.com/api/#/en/fleetappsmanagementrunbooks/20250228/datatypes/ImportRunbookPrecheckRequiredValue.""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
1424
|
+
@cli_util.option('--if-match', help=u"""For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value.""")
|
|
1425
|
+
@cli_util.option('--wait-for-state', type=custom_types.CliCaseInsensitiveChoice(["ACCEPTED", "IN_PROGRESS", "WAITING", "NEEDS_ATTENTION", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED"]), multiple=True, help="""This operation asynchronously creates, modifies or deletes a resource and uses a work request to track the progress of the operation. Specify this option to perform the action and then wait until the work request reaches a certain state. Multiple states can be specified, returning on the first state. For example, --wait-for-state SUCCEEDED --wait-for-state FAILED would return on whichever lifecycle state is reached first. If timeout is reached, a return code of 2 is returned. For any other error, a return code of 1 is returned.""")
|
|
1426
|
+
@cli_util.option('--max-wait-seconds', type=click.INT, help="""The maximum time to wait for the work request to reach the state defined by --wait-for-state. Defaults to 1200 seconds.""")
|
|
1427
|
+
@cli_util.option('--wait-interval-seconds', type=click.INT, help="""Check every --wait-interval-seconds to see whether the work request has reached the state defined by --wait-for-state. Defaults to 30 seconds.""")
|
|
1428
|
+
@json_skeleton_utils.get_cli_json_input_option({'content-source': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}, 'content-destination': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}, 'import-as': {'module': 'fleet_apps_management', 'class': 'RunbookImportAs'}, 'required-values': {'module': 'fleet_apps_management', 'class': 'list[ImportRunbookPrecheckRequiredValue]'}})
|
|
1429
|
+
@cli_util.help_option
|
|
1430
|
+
@click.pass_context
|
|
1431
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={'content-source': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}, 'content-destination': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}, 'import-as': {'module': 'fleet_apps_management', 'class': 'RunbookImportAs'}, 'required-values': {'module': 'fleet_apps_management', 'class': 'list[ImportRunbookPrecheckRequiredValue]'}})
|
|
1432
|
+
@cli_util.wrap_exceptions
|
|
1433
|
+
def import_runbook_precheck(ctx, from_json, wait_for_state, max_wait_seconds, wait_interval_seconds, compartment_id, content_source, content_destination, import_as, required_values, if_match):
|
|
1434
|
+
|
|
1435
|
+
kwargs = {}
|
|
1436
|
+
if if_match is not None:
|
|
1437
|
+
kwargs['if_match'] = if_match
|
|
1438
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
1439
|
+
|
|
1440
|
+
_details = {}
|
|
1441
|
+
_details['compartmentId'] = compartment_id
|
|
1442
|
+
_details['contentSource'] = cli_util.parse_json_parameter("content_source", content_source)
|
|
1443
|
+
_details['contentDestination'] = cli_util.parse_json_parameter("content_destination", content_destination)
|
|
1444
|
+
|
|
1445
|
+
if import_as is not None:
|
|
1446
|
+
_details['importAs'] = cli_util.parse_json_parameter("import_as", import_as)
|
|
1447
|
+
|
|
1448
|
+
if required_values is not None:
|
|
1449
|
+
_details['requiredValues'] = cli_util.parse_json_parameter("required_values", required_values)
|
|
1450
|
+
|
|
1451
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
1452
|
+
result = client.import_runbook_precheck(
|
|
1453
|
+
import_runbook_precheck_details=_details,
|
|
1454
|
+
**kwargs
|
|
1455
|
+
)
|
|
1456
|
+
if wait_for_state:
|
|
1457
|
+
|
|
1458
|
+
if hasattr(client, 'get_work_request') and callable(getattr(client, 'get_work_request')):
|
|
1459
|
+
try:
|
|
1460
|
+
wait_period_kwargs = {}
|
|
1461
|
+
if max_wait_seconds is not None:
|
|
1462
|
+
wait_period_kwargs['max_wait_seconds'] = max_wait_seconds
|
|
1463
|
+
if wait_interval_seconds is not None:
|
|
1464
|
+
wait_period_kwargs['max_interval_seconds'] = wait_interval_seconds
|
|
1465
|
+
if 'opc-work-request-id' not in result.headers:
|
|
1466
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state')
|
|
1467
|
+
cli_util.render_response(result, ctx)
|
|
1468
|
+
return
|
|
1469
|
+
|
|
1470
|
+
click.echo('Action completed. Waiting until the work request has entered state: {}'.format(wait_for_state), file=sys.stderr)
|
|
1471
|
+
result = oci.wait_until(client, client.get_work_request(result.headers['opc-work-request-id']), 'status', wait_for_state, **wait_period_kwargs)
|
|
1472
|
+
except oci.exceptions.MaximumWaitTimeExceeded as e:
|
|
1473
|
+
# If we fail, we should show an error, but we should still provide the information to the customer
|
|
1474
|
+
click.echo('Failed to wait until the work request entered the specified state. Outputting last known resource state', file=sys.stderr)
|
|
1475
|
+
cli_util.render_response(result, ctx)
|
|
1476
|
+
sys.exit(2)
|
|
1477
|
+
except Exception:
|
|
1478
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state', file=sys.stderr)
|
|
1479
|
+
cli_util.render_response(result, ctx)
|
|
1480
|
+
raise
|
|
1481
|
+
else:
|
|
1482
|
+
click.echo('Unable to wait for the work request to enter the specified state', file=sys.stderr)
|
|
1483
|
+
cli_util.render_response(result, ctx)
|
|
1484
|
+
|
|
1485
|
+
|
|
1486
|
+
@import_runbook_version_details_group.command(name=cli_util.override('fleet_apps_management_runbooks.import_runbook_version.command_name', 'import-runbook-version'), help=u"""Export the specified version of the runbook. \n[Command Reference](importRunbookVersion)""")
|
|
1487
|
+
@cli_util.option('--compartment-id', required=True, help=u"""OCID of the compartment to which the resource belongs to.""")
|
|
1488
|
+
@cli_util.option('--content-source', required=True, type=custom_types.CLI_COMPLEX_TYPE, help=u"""""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
1489
|
+
@cli_util.option('--content-destination', required=True, type=custom_types.CLI_COMPLEX_TYPE, help=u"""""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
1490
|
+
@cli_util.option('--runbook-id', help=u"""The OCID of the resource.""")
|
|
1491
|
+
@cli_util.option('--import-option', help=u"""ImportOptions for Runbook.""")
|
|
1492
|
+
@cli_util.option('--version-parameterconflict', help=u"""Version number.""")
|
|
1493
|
+
@cli_util.option('--required-values', type=custom_types.CLI_COMPLEX_TYPE, help=u"""List of required values.
|
|
1494
|
+
|
|
1495
|
+
This option is a JSON list with items of type RunbookImportRequiredValue. For documentation on RunbookImportRequiredValue please see our API reference: https://docs.cloud.oracle.com/api/#/en/fleetappsmanagementrunbooks/20250228/datatypes/RunbookImportRequiredValue.""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
1496
|
+
@cli_util.option('--if-match', help=u"""For optimistic concurrency control. In the PUT or DELETE call for a resource, set the `if-match` parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value.""")
|
|
1497
|
+
@cli_util.option('--wait-for-state', type=custom_types.CliCaseInsensitiveChoice(["ACCEPTED", "IN_PROGRESS", "WAITING", "NEEDS_ATTENTION", "FAILED", "SUCCEEDED", "CANCELING", "CANCELED"]), multiple=True, help="""This operation asynchronously creates, modifies or deletes a resource and uses a work request to track the progress of the operation. Specify this option to perform the action and then wait until the work request reaches a certain state. Multiple states can be specified, returning on the first state. For example, --wait-for-state SUCCEEDED --wait-for-state FAILED would return on whichever lifecycle state is reached first. If timeout is reached, a return code of 2 is returned. For any other error, a return code of 1 is returned.""")
|
|
1498
|
+
@cli_util.option('--max-wait-seconds', type=click.INT, help="""The maximum time to wait for the work request to reach the state defined by --wait-for-state. Defaults to 1200 seconds.""")
|
|
1499
|
+
@cli_util.option('--wait-interval-seconds', type=click.INT, help="""Check every --wait-interval-seconds to see whether the work request has reached the state defined by --wait-for-state. Defaults to 30 seconds.""")
|
|
1500
|
+
@json_skeleton_utils.get_cli_json_input_option({'content-source': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}, 'content-destination': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}, 'required-values': {'module': 'fleet_apps_management', 'class': 'list[RunbookImportRequiredValue]'}})
|
|
1501
|
+
@cli_util.help_option
|
|
1502
|
+
@click.pass_context
|
|
1503
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={'content-source': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}, 'content-destination': {'module': 'fleet_apps_management', 'class': 'TransferRunbookContentDetails'}, 'required-values': {'module': 'fleet_apps_management', 'class': 'list[RunbookImportRequiredValue]'}})
|
|
1504
|
+
@cli_util.wrap_exceptions
|
|
1505
|
+
def import_runbook_version(ctx, from_json, wait_for_state, max_wait_seconds, wait_interval_seconds, compartment_id, content_source, content_destination, runbook_id, import_option, version_parameterconflict, required_values, if_match):
|
|
1506
|
+
|
|
1507
|
+
kwargs = {}
|
|
1508
|
+
if if_match is not None:
|
|
1509
|
+
kwargs['if_match'] = if_match
|
|
1510
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
1511
|
+
|
|
1512
|
+
_details = {}
|
|
1513
|
+
_details['compartmentId'] = compartment_id
|
|
1514
|
+
_details['contentSource'] = cli_util.parse_json_parameter("content_source", content_source)
|
|
1515
|
+
_details['contentDestination'] = cli_util.parse_json_parameter("content_destination", content_destination)
|
|
1516
|
+
|
|
1517
|
+
if runbook_id is not None:
|
|
1518
|
+
_details['runbookId'] = runbook_id
|
|
1519
|
+
|
|
1520
|
+
if import_option is not None:
|
|
1521
|
+
_details['importOption'] = import_option
|
|
1522
|
+
|
|
1523
|
+
if version_parameterconflict is not None:
|
|
1524
|
+
_details['version'] = version_parameterconflict
|
|
1525
|
+
|
|
1526
|
+
if required_values is not None:
|
|
1527
|
+
_details['requiredValues'] = cli_util.parse_json_parameter("required_values", required_values)
|
|
1528
|
+
|
|
1529
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
1530
|
+
result = client.import_runbook_version(
|
|
1531
|
+
import_runbook_version_details=_details,
|
|
1532
|
+
**kwargs
|
|
1533
|
+
)
|
|
1534
|
+
if wait_for_state:
|
|
1535
|
+
|
|
1536
|
+
if hasattr(client, 'get_work_request') and callable(getattr(client, 'get_work_request')):
|
|
1537
|
+
try:
|
|
1538
|
+
wait_period_kwargs = {}
|
|
1539
|
+
if max_wait_seconds is not None:
|
|
1540
|
+
wait_period_kwargs['max_wait_seconds'] = max_wait_seconds
|
|
1541
|
+
if wait_interval_seconds is not None:
|
|
1542
|
+
wait_period_kwargs['max_interval_seconds'] = wait_interval_seconds
|
|
1543
|
+
if 'opc-work-request-id' not in result.headers:
|
|
1544
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state')
|
|
1545
|
+
cli_util.render_response(result, ctx)
|
|
1546
|
+
return
|
|
1547
|
+
|
|
1548
|
+
click.echo('Action completed. Waiting until the work request has entered state: {}'.format(wait_for_state), file=sys.stderr)
|
|
1549
|
+
result = oci.wait_until(client, client.get_work_request(result.headers['opc-work-request-id']), 'status', wait_for_state, **wait_period_kwargs)
|
|
1550
|
+
except oci.exceptions.MaximumWaitTimeExceeded as e:
|
|
1551
|
+
# If we fail, we should show an error, but we should still provide the information to the customer
|
|
1552
|
+
click.echo('Failed to wait until the work request entered the specified state. Outputting last known resource state', file=sys.stderr)
|
|
1553
|
+
cli_util.render_response(result, ctx)
|
|
1554
|
+
sys.exit(2)
|
|
1555
|
+
except Exception:
|
|
1556
|
+
click.echo('Encountered error while waiting for work request to enter the specified state. Outputting last known resource state', file=sys.stderr)
|
|
1557
|
+
cli_util.render_response(result, ctx)
|
|
1558
|
+
raise
|
|
1559
|
+
else:
|
|
1560
|
+
click.echo('Unable to wait for the work request to enter the specified state', file=sys.stderr)
|
|
1561
|
+
cli_util.render_response(result, ctx)
|
|
1562
|
+
|
|
1563
|
+
|
|
1564
|
+
@runbook_export_status_collection_group.command(name=cli_util.override('fleet_apps_management_runbooks.list_runbook_export_statuses.command_name', 'list-runbook-export-statuses'), help=u"""Returns a list of all the Runbook export status in the specified compartment. The query parameter `compartmentId` is required. \n[Command Reference](listRunbookExportStatuses)""")
|
|
1565
|
+
@cli_util.option('--compartment-id', required=True, help=u"""The ID of the compartment in which to list resources.""")
|
|
1566
|
+
@cli_util.option('--id', help=u"""Unique identifier or OCID for listing a single Runbook by id. Either compartmentId or id must be provided.""")
|
|
1567
|
+
@cli_util.option('--limit', type=click.INT, help=u"""The maximum number of items to return.""")
|
|
1568
|
+
@cli_util.option('--page', help=u"""A token representing the position at which to start retrieving results. This must come from the `opc-next-page` header field of a previous response.""")
|
|
1569
|
+
@cli_util.option('--sort-order', type=custom_types.CliCaseInsensitiveChoice(["ASC", "DESC"]), help=u"""The sort order to use, either 'ASC' or 'DESC'.""")
|
|
1570
|
+
@cli_util.option('--sort-by', type=custom_types.CliCaseInsensitiveChoice(["timeCreated", "displayName"]), help=u"""The field to sort by. Only one sort order may be provided. Default order for timeCreated is descending. Default order for displayName is ascending.""")
|
|
1571
|
+
@cli_util.option('--all', 'all_pages', is_flag=True, help="""Fetches all pages of results. If you provide this option, then you cannot provide the --limit option.""")
|
|
1572
|
+
@cli_util.option('--page-size', type=click.INT, help="""When fetching results, the number of results to fetch per call. Only valid when used with --all or --limit, and ignored otherwise.""")
|
|
1573
|
+
@json_skeleton_utils.get_cli_json_input_option({})
|
|
1574
|
+
@cli_util.help_option
|
|
1575
|
+
@click.pass_context
|
|
1576
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={}, output_type={'module': 'fleet_apps_management', 'class': 'RunbookExportStatusCollection'})
|
|
1577
|
+
@cli_util.wrap_exceptions
|
|
1578
|
+
def list_runbook_export_statuses(ctx, from_json, all_pages, page_size, compartment_id, id, limit, page, sort_order, sort_by):
|
|
1579
|
+
|
|
1580
|
+
if all_pages and limit:
|
|
1581
|
+
raise click.UsageError('If you provide the --all option you cannot provide the --limit option')
|
|
1582
|
+
|
|
1583
|
+
kwargs = {}
|
|
1584
|
+
if id is not None:
|
|
1585
|
+
kwargs['id'] = id
|
|
1586
|
+
if limit is not None:
|
|
1587
|
+
kwargs['limit'] = limit
|
|
1588
|
+
if page is not None:
|
|
1589
|
+
kwargs['page'] = page
|
|
1590
|
+
if sort_order is not None:
|
|
1591
|
+
kwargs['sort_order'] = sort_order
|
|
1592
|
+
if sort_by is not None:
|
|
1593
|
+
kwargs['sort_by'] = sort_by
|
|
1594
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
1595
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
1596
|
+
if all_pages:
|
|
1597
|
+
if page_size:
|
|
1598
|
+
kwargs['limit'] = page_size
|
|
1599
|
+
|
|
1600
|
+
result = cli_util.list_call_get_all_results(
|
|
1601
|
+
client.list_runbook_export_statuses,
|
|
1602
|
+
compartment_id=compartment_id,
|
|
1603
|
+
**kwargs
|
|
1604
|
+
)
|
|
1605
|
+
elif limit is not None:
|
|
1606
|
+
result = cli_util.list_call_get_up_to_limit(
|
|
1607
|
+
client.list_runbook_export_statuses,
|
|
1608
|
+
limit,
|
|
1609
|
+
page_size,
|
|
1610
|
+
compartment_id=compartment_id,
|
|
1611
|
+
**kwargs
|
|
1612
|
+
)
|
|
1613
|
+
else:
|
|
1614
|
+
result = client.list_runbook_export_statuses(
|
|
1615
|
+
compartment_id=compartment_id,
|
|
1616
|
+
**kwargs
|
|
1617
|
+
)
|
|
1618
|
+
cli_util.render_response(result, ctx)
|
|
1619
|
+
|
|
1620
|
+
|
|
1621
|
+
@runbook_import_status_collection_group.command(name=cli_util.override('fleet_apps_management_runbooks.list_runbook_import_statuses.command_name', 'list-runbook-import-statuses'), help=u"""Returns a list of all the Runbook import status in the specified compartment. The query parameter `compartmentId` is required. \n[Command Reference](listRunbookImportStatuses)""")
|
|
1622
|
+
@cli_util.option('--compartment-id', required=True, help=u"""The ID of the compartment in which to list resources.""")
|
|
1623
|
+
@cli_util.option('--id', help=u"""Unique identifier or OCID for listing a single Runbook by id. Either compartmentId or id must be provided.""")
|
|
1624
|
+
@cli_util.option('--limit', type=click.INT, help=u"""The maximum number of items to return.""")
|
|
1625
|
+
@cli_util.option('--page', help=u"""A token representing the position at which to start retrieving results. This must come from the `opc-next-page` header field of a previous response.""")
|
|
1626
|
+
@cli_util.option('--sort-order', type=custom_types.CliCaseInsensitiveChoice(["ASC", "DESC"]), help=u"""The sort order to use, either 'ASC' or 'DESC'.""")
|
|
1627
|
+
@cli_util.option('--sort-by', type=custom_types.CliCaseInsensitiveChoice(["timeCreated", "displayName"]), help=u"""The field to sort by. Only one sort order may be provided. Default order for timeCreated is descending. Default order for displayName is ascending.""")
|
|
1628
|
+
@cli_util.option('--all', 'all_pages', is_flag=True, help="""Fetches all pages of results. If you provide this option, then you cannot provide the --limit option.""")
|
|
1629
|
+
@cli_util.option('--page-size', type=click.INT, help="""When fetching results, the number of results to fetch per call. Only valid when used with --all or --limit, and ignored otherwise.""")
|
|
1630
|
+
@json_skeleton_utils.get_cli_json_input_option({})
|
|
1631
|
+
@cli_util.help_option
|
|
1632
|
+
@click.pass_context
|
|
1633
|
+
@json_skeleton_utils.json_skeleton_generation_handler(input_params_to_complex_types={}, output_type={'module': 'fleet_apps_management', 'class': 'RunbookImportStatusCollection'})
|
|
1634
|
+
@cli_util.wrap_exceptions
|
|
1635
|
+
def list_runbook_import_statuses(ctx, from_json, all_pages, page_size, compartment_id, id, limit, page, sort_order, sort_by):
|
|
1636
|
+
|
|
1637
|
+
if all_pages and limit:
|
|
1638
|
+
raise click.UsageError('If you provide the --all option you cannot provide the --limit option')
|
|
1639
|
+
|
|
1640
|
+
kwargs = {}
|
|
1641
|
+
if id is not None:
|
|
1642
|
+
kwargs['id'] = id
|
|
1643
|
+
if limit is not None:
|
|
1644
|
+
kwargs['limit'] = limit
|
|
1645
|
+
if page is not None:
|
|
1646
|
+
kwargs['page'] = page
|
|
1647
|
+
if sort_order is not None:
|
|
1648
|
+
kwargs['sort_order'] = sort_order
|
|
1649
|
+
if sort_by is not None:
|
|
1650
|
+
kwargs['sort_by'] = sort_by
|
|
1651
|
+
kwargs['opc_request_id'] = cli_util.use_or_generate_request_id(ctx.obj['request_id'])
|
|
1652
|
+
client = cli_util.build_client('fleet_apps_management', 'fleet_apps_management_runbooks', ctx)
|
|
1653
|
+
if all_pages:
|
|
1654
|
+
if page_size:
|
|
1655
|
+
kwargs['limit'] = page_size
|
|
1656
|
+
|
|
1657
|
+
result = cli_util.list_call_get_all_results(
|
|
1658
|
+
client.list_runbook_import_statuses,
|
|
1659
|
+
compartment_id=compartment_id,
|
|
1660
|
+
**kwargs
|
|
1661
|
+
)
|
|
1662
|
+
elif limit is not None:
|
|
1663
|
+
result = cli_util.list_call_get_up_to_limit(
|
|
1664
|
+
client.list_runbook_import_statuses,
|
|
1665
|
+
limit,
|
|
1666
|
+
page_size,
|
|
1667
|
+
compartment_id=compartment_id,
|
|
1668
|
+
**kwargs
|
|
1669
|
+
)
|
|
1670
|
+
else:
|
|
1671
|
+
result = client.list_runbook_import_statuses(
|
|
1672
|
+
compartment_id=compartment_id,
|
|
1673
|
+
**kwargs
|
|
1674
|
+
)
|
|
654
1675
|
cli_util.render_response(result, ctx)
|
|
655
1676
|
|
|
656
1677
|
|
|
@@ -1056,7 +2077,7 @@ def update_runbook(ctx, from_json, force, wait_for_state, max_wait_seconds, wait
|
|
|
1056
2077
|
@cli_util.option('--tasks', type=custom_types.CLI_COMPLEX_TYPE, help=u"""A set of tasks to execute in the runbook.
|
|
1057
2078
|
|
|
1058
2079
|
This option is a JSON list with items of type Task. For documentation on Task please see our API reference: https://docs.cloud.oracle.com/api/#/en/fleetappsmanagementrunbooks/20250228/datatypes/Task.""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
1059
|
-
@cli_util.option('--groups', type=custom_types.CLI_COMPLEX_TYPE, help=u"""The groups of the runbook.
|
|
2080
|
+
@cli_util.option('--groups', type=custom_types.CLI_COMPLEX_TYPE, help=u"""The groups of the runbook version.
|
|
1060
2081
|
|
|
1061
2082
|
This option is a JSON list with items of type Group. For documentation on Group please see our API reference: https://docs.cloud.oracle.com/api/#/en/fleetappsmanagementrunbooks/20250228/datatypes/Group.""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|
|
1062
2083
|
@cli_util.option('--execution-workflow-details', type=custom_types.CLI_COMPLEX_TYPE, help=u"""""" + custom_types.cli_complex_type.COMPLEX_TYPE_HELP)
|