anyscale 0.24.86__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.
- anyscale/__init__.py +181 -0
- anyscale/_private/anyscale_client/README.md +16 -0
- anyscale/_private/anyscale_client/__init__.py +8 -0
- anyscale/_private/anyscale_client/anyscale_client.py +1847 -0
- anyscale/_private/anyscale_client/common.py +593 -0
- anyscale/_private/anyscale_client/fake_anyscale_client.py +1080 -0
- anyscale/_private/docgen/README.md +15 -0
- anyscale/_private/docgen/__main__.py +700 -0
- anyscale/_private/docgen/api.md +1106 -0
- anyscale/_private/docgen/generator.py +559 -0
- anyscale/_private/docgen/generator_legacy.py +104 -0
- anyscale/_private/docgen/models.md +2261 -0
- anyscale/_private/models/__init__.py +2 -0
- anyscale/_private/models/image_uri.py +116 -0
- anyscale/_private/models/model_base.py +251 -0
- anyscale/_private/sdk/__init__.py +102 -0
- anyscale/_private/sdk/base_sdk.py +35 -0
- anyscale/_private/sdk/timer.py +46 -0
- anyscale/_private/utils/__init__.py +0 -0
- anyscale/_private/utils/progress_util.py +85 -0
- anyscale/_private/workload/__init__.py +2 -0
- anyscale/_private/workload/workload_config.py +195 -0
- anyscale/_private/workload/workload_sdk.py +324 -0
- anyscale/aggregated_instance_usage/__init__.py +36 -0
- anyscale/aggregated_instance_usage/_private/aggregated_instance_usage_sdk.py +30 -0
- anyscale/aggregated_instance_usage/commands.py +42 -0
- anyscale/aggregated_instance_usage/models.py +85 -0
- anyscale/anyscale-cloud-setup-gcp-oa.yaml +88 -0
- anyscale/anyscale-cloud-setup-gcp.yaml +113 -0
- anyscale/anyscale-cloud-setup-oa.yaml +121 -0
- anyscale/anyscale-cloud-setup.yaml +327 -0
- anyscale/anyscale_pydantic/HISTORY.md +1254 -0
- anyscale/anyscale_pydantic/LICENSE +21 -0
- anyscale/anyscale_pydantic/PKG-INFO +1351 -0
- anyscale/anyscale_pydantic/README.md +7 -0
- anyscale/anyscale_pydantic/__init__.py +131 -0
- anyscale/anyscale_pydantic/_hypothesis_plugin.py +391 -0
- anyscale/anyscale_pydantic/annotated_types.py +72 -0
- anyscale/anyscale_pydantic/class_validators.py +361 -0
- anyscale/anyscale_pydantic/color.py +494 -0
- anyscale/anyscale_pydantic/config.py +191 -0
- anyscale/anyscale_pydantic/dataclasses.py +478 -0
- anyscale/anyscale_pydantic/datetime_parse.py +248 -0
- anyscale/anyscale_pydantic/decorator.py +264 -0
- anyscale/anyscale_pydantic/env_settings.py +350 -0
- anyscale/anyscale_pydantic/error_wrappers.py +162 -0
- anyscale/anyscale_pydantic/errors.py +646 -0
- anyscale/anyscale_pydantic/fields.py +1256 -0
- anyscale/anyscale_pydantic/generics.py +400 -0
- anyscale/anyscale_pydantic/json.py +112 -0
- anyscale/anyscale_pydantic/main.py +1109 -0
- anyscale/anyscale_pydantic/mypy.py +943 -0
- anyscale/anyscale_pydantic/networks.py +739 -0
- anyscale/anyscale_pydantic/parse.py +66 -0
- anyscale/anyscale_pydantic/py.typed +0 -0
- anyscale/anyscale_pydantic/schema.py +1164 -0
- anyscale/anyscale_pydantic/tools.py +92 -0
- anyscale/anyscale_pydantic/types.py +1206 -0
- anyscale/anyscale_pydantic/typing.py +603 -0
- anyscale/anyscale_pydantic/utils.py +803 -0
- anyscale/anyscale_pydantic/validators.py +765 -0
- anyscale/anyscale_pydantic/version.py +38 -0
- anyscale/anyscale_schema.json +9 -0
- anyscale/api.py +215 -0
- anyscale/api_utils/README.md +2 -0
- anyscale/api_utils/__init__.py +0 -0
- anyscale/api_utils/common_utils.py +81 -0
- anyscale/api_utils/exceptions/__init__.py +0 -0
- anyscale/api_utils/exceptions/job_errors.py +2 -0
- anyscale/api_utils/job_logs_util.py +116 -0
- anyscale/api_utils/job_util.py +22 -0
- anyscale/api_utils/logs_util.py +61 -0
- anyscale/authenticate.py +298 -0
- anyscale/aws_iam_policies.py +465 -0
- anyscale/background/__init__.py +0 -0
- anyscale/background/job_runner.py +64 -0
- anyscale/cli_logger.py +378 -0
- anyscale/client/.gitignore +66 -0
- anyscale/client/.openapi-generator/VERSION +1 -0
- anyscale/client/.openapi-generator-ignore +23 -0
- anyscale/client/README.md +1070 -0
- anyscale/client/git_push.sh +58 -0
- anyscale/client/openapi_client/__init__.py +667 -0
- anyscale/client/openapi_client/api/__init__.py +6 -0
- anyscale/client/openapi_client/api/default_api.py +40922 -0
- anyscale/client/openapi_client/api_client.py +647 -0
- anyscale/client/openapi_client/configuration.py +373 -0
- anyscale/client/openapi_client/exceptions.py +120 -0
- anyscale/client/openapi_client/models/__init__.py +652 -0
- anyscale/client/openapi_client/models/access_config.py +122 -0
- anyscale/client/openapi_client/models/aggregated_instance_usage_with_cost_model.py +733 -0
- anyscale/client/openapi_client/models/aggregatedinstanceusagewithcostmodel_list_response.py +147 -0
- anyscale/client/openapi_client/models/aica_endpoint.py +527 -0
- anyscale/client/openapi_client/models/aica_endpoint_event.py +433 -0
- anyscale/client/openapi_client/models/aica_endpoint_event_level.py +103 -0
- anyscale/client/openapi_client/models/aica_endpoint_event_type.py +120 -0
- anyscale/client/openapi_client/models/aica_endpoint_scope.py +102 -0
- anyscale/client/openapi_client/models/aica_model.py +398 -0
- anyscale/client/openapi_client/models/aica_model_accelerator_map.py +123 -0
- anyscale/client/openapi_client/models/aica_model_configuration.py +209 -0
- anyscale/client/openapi_client/models/aica_observability_urls.py +178 -0
- anyscale/client/openapi_client/models/aicaendpoint_list_response.py +147 -0
- anyscale/client/openapi_client/models/aicaendpoint_response.py +121 -0
- anyscale/client/openapi_client/models/aicaendpointevent_list_response.py +147 -0
- anyscale/client/openapi_client/models/aicamodel_list_response.py +147 -0
- anyscale/client/openapi_client/models/aicamodel_response.py +121 -0
- anyscale/client/openapi_client/models/aioa_cloud_waitlist_record.py +254 -0
- anyscale/client/openapi_client/models/aioacloudwaitlistrecord_response.py +121 -0
- anyscale/client/openapi_client/models/alert_type.py +103 -0
- anyscale/client/openapi_client/models/anyscale_aws_account.py +121 -0
- anyscale/client/openapi_client/models/anyscale_service_account.py +256 -0
- anyscale/client/openapi_client/models/anyscale_version_response.py +121 -0
- anyscale/client/openapi_client/models/anyscaleawsaccount_response.py +121 -0
- anyscale/client/openapi_client/models/anyscaled_credential_response.py +121 -0
- anyscale/client/openapi_client/models/anyscaledcredentialresponse_response.py +121 -0
- anyscale/client/openapi_client/models/anyscaleserviceaccount_response.py +121 -0
- anyscale/client/openapi_client/models/anyscaleversionresponse_response.py +121 -0
- anyscale/client/openapi_client/models/api_key_parameters.py +147 -0
- anyscale/client/openapi_client/models/app_config.py +436 -0
- anyscale/client/openapi_client/models/app_config_config_schema.py +235 -0
- anyscale/client/openapi_client/models/appconfig_list_response.py +147 -0
- anyscale/client/openapi_client/models/appconfig_response.py +121 -0
- anyscale/client/openapi_client/models/application_type.py +99 -0
- anyscale/client/openapi_client/models/applied_snapshot.py +175 -0
- anyscale/client/openapi_client/models/apply_production_service_v2_model.py +490 -0
- anyscale/client/openapi_client/models/archive_status.py +101 -0
- anyscale/client/openapi_client/models/archived_logs_info.py +164 -0
- anyscale/client/openapi_client/models/archivedlogsinfo_response.py +121 -0
- anyscale/client/openapi_client/models/attach_machine_pool_to_cloud_request.py +152 -0
- anyscale/client/openapi_client/models/attachmachinepooltocloudresponse_response.py +121 -0
- anyscale/client/openapi_client/models/aviary_model_config_v2.py +358 -0
- anyscale/client/openapi_client/models/aws_credentials.py +181 -0
- anyscale/client/openapi_client/models/aws_memory_db_cluster_config.py +148 -0
- anyscale/client/openapi_client/models/aws_region_and_zones.py +123 -0
- anyscale/client/openapi_client/models/aws_region_info.py +152 -0
- anyscale/client/openapi_client/models/awsregionandzones_response.py +121 -0
- anyscale/client/openapi_client/models/bank_account_information.py +239 -0
- anyscale/client/openapi_client/models/base_job_status.py +105 -0
- anyscale/client/openapi_client/models/baseimagesenum.py +2130 -0
- anyscale/client/openapi_client/models/batch_response_batched_result_organization_invitation_base.py +121 -0
- anyscale/client/openapi_client/models/batched_result_organization_invitation_base.py +173 -0
- anyscale/client/openapi_client/models/billing_information.py +181 -0
- anyscale/client/openapi_client/models/billing_version_code.py +100 -0
- anyscale/client/openapi_client/models/body_aws_marketplace_registration_api_v2_organization_billing_aws_marketplace_registration_post.py +121 -0
- anyscale/client/openapi_client/models/buffer_registration.py +285 -0
- anyscale/client/openapi_client/models/build.py +607 -0
- anyscale/client/openapi_client/models/build_log_response.py +123 -0
- anyscale/client/openapi_client/models/build_registration.py +285 -0
- anyscale/client/openapi_client/models/build_response.py +121 -0
- anyscale/client/openapi_client/models/build_status.py +104 -0
- anyscale/client/openapi_client/models/buildlogresponse_response.py +121 -0
- anyscale/client/openapi_client/models/card.py +181 -0
- anyscale/client/openapi_client/models/card_id.py +108 -0
- anyscale/client/openapi_client/models/card_list_response.py +147 -0
- anyscale/client/openapi_client/models/change_password_params.py +148 -0
- anyscale/client/openapi_client/models/cleanup_leaked_grafana_dashboard_response.py +208 -0
- anyscale/client/openapi_client/models/cleanupleakedgrafanadashboardresponse_response.py +121 -0
- anyscale/client/openapi_client/models/clone_experimental_workspace.py +151 -0
- anyscale/client/openapi_client/models/cloud.py +802 -0
- anyscale/client/openapi_client/models/cloud_analytics_event.py +351 -0
- anyscale/client/openapi_client/models/cloud_analytics_event_cloud_provider_error.py +152 -0
- anyscale/client/openapi_client/models/cloud_analytics_event_cloud_resource.py +117 -0
- anyscale/client/openapi_client/models/cloud_analytics_event_command_name.py +103 -0
- anyscale/client/openapi_client/models/cloud_analytics_event_error.py +150 -0
- anyscale/client/openapi_client/models/cloud_analytics_event_name.py +109 -0
- anyscale/client/openapi_client/models/cloud_collaborator.py +175 -0
- anyscale/client/openapi_client/models/cloud_collaborator_value.py +177 -0
- anyscale/client/openapi_client/models/cloud_collaborators_query.py +122 -0
- anyscale/client/openapi_client/models/cloud_config.py +206 -0
- anyscale/client/openapi_client/models/cloud_data_bucket_access_mode.py +100 -0
- anyscale/client/openapi_client/models/cloud_data_bucket_file_type.py +102 -0
- anyscale/client/openapi_client/models/cloud_data_bucket_presigned_upload_info.py +268 -0
- anyscale/client/openapi_client/models/cloud_data_bucket_presigned_upload_request.py +152 -0
- anyscale/client/openapi_client/models/cloud_data_bucket_presigned_upload_scheme.py +100 -0
- anyscale/client/openapi_client/models/cloud_data_bucket_presigned_url_request.py +209 -0
- anyscale/client/openapi_client/models/cloud_data_bucket_presigned_url_response.py +296 -0
- anyscale/client/openapi_client/models/cloud_data_bucket_presigned_url_scheme.py +100 -0
- anyscale/client/openapi_client/models/cloud_data_bucket_request_scope.py +100 -0
- anyscale/client/openapi_client/models/cloud_hosting_type.py +100 -0
- anyscale/client/openapi_client/models/cloud_list_response.py +147 -0
- anyscale/client/openapi_client/models/cloud_name_options.py +121 -0
- anyscale/client/openapi_client/models/cloud_overview_dashboard.py +175 -0
- anyscale/client/openapi_client/models/cloud_project_collaborator.py +175 -0
- anyscale/client/openapi_client/models/cloud_project_collaborator_value.py +121 -0
- anyscale/client/openapi_client/models/cloud_provider.py +102 -0
- anyscale/client/openapi_client/models/cloud_providers.py +103 -0
- anyscale/client/openapi_client/models/cloud_region_and_zones.py +123 -0
- anyscale/client/openapi_client/models/cloud_region_info.py +152 -0
- anyscale/client/openapi_client/models/cloud_resource.py +740 -0
- anyscale/client/openapi_client/models/cloud_resource_gcp.py +691 -0
- anyscale/client/openapi_client/models/cloud_response.py +121 -0
- anyscale/client/openapi_client/models/cloud_state.py +104 -0
- anyscale/client/openapi_client/models/cloud_status.py +100 -0
- anyscale/client/openapi_client/models/cloud_type.py +100 -0
- anyscale/client/openapi_client/models/cloud_types.py +100 -0
- anyscale/client/openapi_client/models/cloud_version.py +100 -0
- anyscale/client/openapi_client/models/cloud_waitlist_status.py +102 -0
- anyscale/client/openapi_client/models/cloud_with_cloud_resource.py +830 -0
- anyscale/client/openapi_client/models/cloud_with_cloud_resource_gcp.py +830 -0
- anyscale/client/openapi_client/models/cloudcollaborator_list_response.py +147 -0
- anyscale/client/openapi_client/models/clouddatabucketpresigneduploadinfo_response.py +121 -0
- anyscale/client/openapi_client/models/clouddatabucketpresignedurlresponse_response.py +121 -0
- anyscale/client/openapi_client/models/cloudoverviewdashboard_response.py +121 -0
- anyscale/client/openapi_client/models/cloudregionandzones_response.py +121 -0
- anyscale/client/openapi_client/models/cloudresource_response.py +121 -0
- anyscale/client/openapi_client/models/cloudresourcegcp_response.py +121 -0
- anyscale/client/openapi_client/models/cloudwithcloudresource_response.py +121 -0
- anyscale/client/openapi_client/models/cloudwithcloudresourcegcp_response.py +121 -0
- anyscale/client/openapi_client/models/cluster_auth_response.py +148 -0
- anyscale/client/openapi_client/models/cluster_config.py +178 -0
- anyscale/client/openapi_client/models/cluster_config_with_session_idle_timeout.py +204 -0
- anyscale/client/openapi_client/models/cluster_environments_query.py +290 -0
- anyscale/client/openapi_client/models/cluster_event.py +174 -0
- anyscale/client/openapi_client/models/cluster_events_output.py +175 -0
- anyscale/client/openapi_client/models/cluster_features.py +152 -0
- anyscale/client/openapi_client/models/cluster_management_stack_versions.py +100 -0
- anyscale/client/openapi_client/models/cluster_startup.py +208 -0
- anyscale/client/openapi_client/models/cluster_status.py +104 -0
- anyscale/client/openapi_client/models/cluster_status_details.py +100 -0
- anyscale/client/openapi_client/models/clusterauthresponse_response.py +121 -0
- anyscale/client/openapi_client/models/clusterconfig_response.py +121 -0
- anyscale/client/openapi_client/models/clusterconfigwithsessionidletimeout_response.py +121 -0
- anyscale/client/openapi_client/models/clustereventsoutput_response.py +121 -0
- anyscale/client/openapi_client/models/clusterfeatures_response.py +121 -0
- anyscale/client/openapi_client/models/company_size.py +103 -0
- anyscale/client/openapi_client/models/compute_node_type.py +292 -0
- anyscale/client/openapi_client/models/compute_stack.py +100 -0
- anyscale/client/openapi_client/models/compute_template.py +415 -0
- anyscale/client/openapi_client/models/compute_template_config.py +461 -0
- anyscale/client/openapi_client/models/compute_template_query.py +316 -0
- anyscale/client/openapi_client/models/computetemplate_response.py +121 -0
- anyscale/client/openapi_client/models/computetemplateconfig_response.py +121 -0
- anyscale/client/openapi_client/models/create_aica_endpoint.py +210 -0
- anyscale/client/openapi_client/models/create_aioa_cloud_waitlist.py +173 -0
- anyscale/client/openapi_client/models/create_analytics_event.py +122 -0
- anyscale/client/openapi_client/models/create_app_config.py +235 -0
- anyscale/client/openapi_client/models/create_app_config_configuration_schema.py +235 -0
- anyscale/client/openapi_client/models/create_billing_version.py +181 -0
- anyscale/client/openapi_client/models/create_bug_report_response.py +152 -0
- anyscale/client/openapi_client/models/create_build.py +263 -0
- anyscale/client/openapi_client/models/create_byod_app_config.py +180 -0
- anyscale/client/openapi_client/models/create_byod_app_config_configuration_schema.py +206 -0
- anyscale/client/openapi_client/models/create_byod_build.py +152 -0
- anyscale/client/openapi_client/models/create_cloud_collaborator.py +148 -0
- anyscale/client/openapi_client/models/create_cloud_resource.py +682 -0
- anyscale/client/openapi_client/models/create_cloud_resource_gcp.py +633 -0
- anyscale/client/openapi_client/models/create_cloud_with_cloud_resource.py +546 -0
- anyscale/client/openapi_client/models/create_cluster_compute_config.py +463 -0
- anyscale/client/openapi_client/models/create_compute_template.py +229 -0
- anyscale/client/openapi_client/models/create_compute_template_config.py +464 -0
- anyscale/client/openapi_client/models/create_dataset.py +200 -0
- anyscale/client/openapi_client/models/create_experimental_workspace.py +435 -0
- anyscale/client/openapi_client/models/create_experimental_workspace_from_job.py +123 -0
- anyscale/client/openapi_client/models/create_fine_tuning_hyperparameters.py +156 -0
- anyscale/client/openapi_client/models/create_fine_tuning_job_product_request.py +353 -0
- anyscale/client/openapi_client/models/create_instance_usage_budget.py +253 -0
- anyscale/client/openapi_client/models/create_internal_production_job.py +262 -0
- anyscale/client/openapi_client/models/create_job_queue_config.py +206 -0
- anyscale/client/openapi_client/models/create_job_queue_requests.py +323 -0
- anyscale/client/openapi_client/models/create_machine_pool_request.py +151 -0
- anyscale/client/openapi_client/models/create_machine_pool_response.py +123 -0
- anyscale/client/openapi_client/models/create_machine_request.py +151 -0
- anyscale/client/openapi_client/models/create_machine_response.py +123 -0
- anyscale/client/openapi_client/models/create_metronome_webhook_notification.py +175 -0
- anyscale/client/openapi_client/models/create_notification_channel_record.py +146 -0
- anyscale/client/openapi_client/models/create_organization_configuration.py +199 -0
- anyscale/client/openapi_client/models/create_organization_invitation.py +121 -0
- anyscale/client/openapi_client/models/create_otp_return_api_model.py +148 -0
- anyscale/client/openapi_client/models/create_production_job_config.py +347 -0
- anyscale/client/openapi_client/models/create_resource_quota.py +293 -0
- anyscale/client/openapi_client/models/create_schedule.py +263 -0
- anyscale/client/openapi_client/models/create_session_from_snapshot_options.py +565 -0
- anyscale/client/openapi_client/models/create_session_in_db.py +434 -0
- anyscale/client/openapi_client/models/create_session_response.py +174 -0
- anyscale/client/openapi_client/models/create_user.py +439 -0
- anyscale/client/openapi_client/models/create_user_project_collaborator.py +148 -0
- anyscale/client/openapi_client/models/create_user_project_collaborator_value.py +121 -0
- anyscale/client/openapi_client/models/create_workspace_from_template.py +263 -0
- anyscale/client/openapi_client/models/createbugreportresponse_response.py +121 -0
- anyscale/client/openapi_client/models/createcomputetemplateconfig_response.py +121 -0
- anyscale/client/openapi_client/models/createmachinepoolresponse_response.py +121 -0
- anyscale/client/openapi_client/models/createmachineresponse_response.py +121 -0
- anyscale/client/openapi_client/models/createotpreturnapimodel_response.py +121 -0
- anyscale/client/openapi_client/models/createsessionresponse_response.py +121 -0
- anyscale/client/openapi_client/models/credit_card_information.py +268 -0
- anyscale/client/openapi_client/models/customer_alert_status.py +101 -0
- anyscale/client/openapi_client/models/customer_billing_type.py +101 -0
- anyscale/client/openapi_client/models/dataplane_services.py +102 -0
- anyscale/client/openapi_client/models/dataset.py +416 -0
- anyscale/client/openapi_client/models/dataset_list_response.py +150 -0
- anyscale/client/openapi_client/models/dataset_response.py +121 -0
- anyscale/client/openapi_client/models/dataset_upload.py +148 -0
- anyscale/client/openapi_client/models/datasetupload_response.py +121 -0
- anyscale/client/openapi_client/models/decorated_application_template.py +493 -0
- anyscale/client/openapi_client/models/decorated_build.py +664 -0
- anyscale/client/openapi_client/models/decorated_compute_template.py +446 -0
- anyscale/client/openapi_client/models/decorated_compute_template_config.py +490 -0
- anyscale/client/openapi_client/models/decorated_interactive_session.py +793 -0
- anyscale/client/openapi_client/models/decorated_job.py +793 -0
- anyscale/client/openapi_client/models/decorated_job_queue.py +639 -0
- anyscale/client/openapi_client/models/decorated_job_submission.py +575 -0
- anyscale/client/openapi_client/models/decorated_list_service_api_model.py +670 -0
- anyscale/client/openapi_client/models/decorated_production_job.py +805 -0
- anyscale/client/openapi_client/models/decorated_production_job_state_transition.py +319 -0
- anyscale/client/openapi_client/models/decorated_production_service_v2_api_model.py +641 -0
- anyscale/client/openapi_client/models/decorated_production_service_v2_version_api_model.py +437 -0
- anyscale/client/openapi_client/models/decorated_runtime_env.py +488 -0
- anyscale/client/openapi_client/models/decorated_schedule.py +552 -0
- anyscale/client/openapi_client/models/decorated_serve_deployment.py +711 -0
- anyscale/client/openapi_client/models/decorated_service_event_api_model.py +513 -0
- anyscale/client/openapi_client/models/decorated_session.py +1789 -0
- anyscale/client/openapi_client/models/decorated_support_request.py +283 -0
- anyscale/client/openapi_client/models/decorated_unified_job.py +466 -0
- anyscale/client/openapi_client/models/decoratedapplicationtemplate_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedapplicationtemplate_response.py +121 -0
- anyscale/client/openapi_client/models/decoratedbuild_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedbuild_response.py +121 -0
- anyscale/client/openapi_client/models/decoratedcomputetemplate_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedcomputetemplate_response.py +121 -0
- anyscale/client/openapi_client/models/decoratedinteractivesession_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedinteractivesession_response.py +121 -0
- anyscale/client/openapi_client/models/decoratedjob_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedjob_response.py +121 -0
- anyscale/client/openapi_client/models/decoratedjobqueue_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedjobqueue_response.py +121 -0
- anyscale/client/openapi_client/models/decoratedjobsubmission_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedjobsubmission_response.py +121 -0
- anyscale/client/openapi_client/models/decoratedlistserviceapimodel_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedproductionjob_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedproductionjob_response.py +121 -0
- anyscale/client/openapi_client/models/decoratedproductionjobstatetransition_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedproductionservicev2_apimodel_response.py +121 -0
- anyscale/client/openapi_client/models/decoratedproductionservicev2_versionapimodel_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedruntimeenv_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedruntimeenv_response.py +121 -0
- anyscale/client/openapi_client/models/decoratedschedule_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedschedule_response.py +121 -0
- anyscale/client/openapi_client/models/decoratedservedeployment_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedservedeployment_response.py +121 -0
- anyscale/client/openapi_client/models/decoratedserviceeventapimodel_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedsession_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedsession_response.py +121 -0
- anyscale/client/openapi_client/models/decoratedsupportrequest_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedsupportrequest_response.py +121 -0
- anyscale/client/openapi_client/models/decoratedunifiedjob_list_response.py +147 -0
- anyscale/client/openapi_client/models/decoratedunifiedjob_response.py +121 -0
- anyscale/client/openapi_client/models/delete_machine_pool_request.py +123 -0
- anyscale/client/openapi_client/models/delete_machine_request.py +206 -0
- anyscale/client/openapi_client/models/deleted_platform_fine_tuned_model.py +148 -0
- anyscale/client/openapi_client/models/deletedplatformfinetunedmodel_response.py +121 -0
- anyscale/client/openapi_client/models/deletemachinepoolresponse_response.py +121 -0
- anyscale/client/openapi_client/models/detach_machine_pool_from_cloud_request.py +152 -0
- anyscale/client/openapi_client/models/detachmachinepoolfromcloudresponse_response.py +121 -0
- anyscale/client/openapi_client/models/dismissal_type.py +100 -0
- anyscale/client/openapi_client/models/editable_cloud_resource.py +206 -0
- anyscale/client/openapi_client/models/editable_cloud_resource_gcp.py +178 -0
- anyscale/client/openapi_client/models/error.py +174 -0
- anyscale/client/openapi_client/models/event_level.py +104 -0
- anyscale/client/openapi_client/models/execute_command_response.py +175 -0
- anyscale/client/openapi_client/models/execute_interactive_command_options.py +147 -0
- anyscale/client/openapi_client/models/execute_shell_command_options.py +121 -0
- anyscale/client/openapi_client/models/executecommandresponse_response.py +121 -0
- anyscale/client/openapi_client/models/experimental_workspace.py +748 -0
- anyscale/client/openapi_client/models/experimental_workspaces_sort_field.py +100 -0
- anyscale/client/openapi_client/models/experimentalworkspace_list_response.py +147 -0
- anyscale/client/openapi_client/models/experimentalworkspace_response.py +121 -0
- anyscale/client/openapi_client/models/external_service_status.py +147 -0
- anyscale/client/openapi_client/models/external_service_status_response.py +250 -0
- anyscale/client/openapi_client/models/external_terminal_command.py +280 -0
- anyscale/client/openapi_client/models/externalservicestatusresponse_response.py +121 -0
- anyscale/client/openapi_client/models/feature_compatibility.py +152 -0
- anyscale/client/openapi_client/models/feature_flag_response.py +121 -0
- anyscale/client/openapi_client/models/featureflagresponse_response.py +121 -0
- anyscale/client/openapi_client/models/fine_tune_type.py +100 -0
- anyscale/client/openapi_client/models/fine_tuned_model.py +412 -0
- anyscale/client/openapi_client/models/fine_tuning_job_status.py +103 -0
- anyscale/client/openapi_client/models/finetunedmodel_list_response.py +147 -0
- anyscale/client/openapi_client/models/finetunedmodel_response.py +121 -0
- anyscale/client/openapi_client/models/finish_ft_job_request.py +204 -0
- anyscale/client/openapi_client/models/finish_ft_job_request_v2.py +183 -0
- anyscale/client/openapi_client/models/gcp_file_store_config.py +175 -0
- anyscale/client/openapi_client/models/gcp_memorystore_instance_config.py +148 -0
- anyscale/client/openapi_client/models/grafana_dashboard.py +201 -0
- anyscale/client/openapi_client/models/grpc_protocol_config.py +178 -0
- anyscale/client/openapi_client/models/ha_job_error_types.py +103 -0
- anyscale/client/openapi_client/models/ha_job_event_level.py +101 -0
- anyscale/client/openapi_client/models/ha_job_event_origin.py +100 -0
- anyscale/client/openapi_client/models/ha_job_goal_states.py +102 -0
- anyscale/client/openapi_client/models/ha_job_states.py +109 -0
- anyscale/client/openapi_client/models/ha_job_type.py +100 -0
- anyscale/client/openapi_client/models/ha_jobs_sort_field.py +105 -0
- anyscale/client/openapi_client/models/head_ip.py +121 -0
- anyscale/client/openapi_client/models/headip_response.py +121 -0
- anyscale/client/openapi_client/models/http_protocol_config.py +150 -0
- anyscale/client/openapi_client/models/http_validation_error.py +120 -0
- anyscale/client/openapi_client/models/idle_termination_status.py +104 -0
- anyscale/client/openapi_client/models/import_aica_model.py +241 -0
- anyscale/client/openapi_client/models/instance_usage_budget.py +572 -0
- anyscale/client/openapi_client/models/instance_usage_budget_evaluation_period.py +100 -0
- anyscale/client/openapi_client/models/instanceusagebudget_list_response.py +147 -0
- anyscale/client/openapi_client/models/instanceusagebudget_response.py +121 -0
- anyscale/client/openapi_client/models/integration_details.py +120 -0
- anyscale/client/openapi_client/models/interactive_session_logs.py +152 -0
- anyscale/client/openapi_client/models/interactivesessionlogs_response.py +121 -0
- anyscale/client/openapi_client/models/internal_production_job.py +663 -0
- anyscale/client/openapi_client/models/internalproductionjob_response.py +121 -0
- anyscale/client/openapi_client/models/invoice.py +413 -0
- anyscale/client/openapi_client/models/invoice_list_response.py +147 -0
- anyscale/client/openapi_client/models/invoice_status.py +102 -0
- anyscale/client/openapi_client/models/invoices_query.py +150 -0
- anyscale/client/openapi_client/models/job_access.py +102 -0
- anyscale/client/openapi_client/models/job_queue.py +467 -0
- anyscale/client/openapi_client/models/job_queue_config.py +122 -0
- anyscale/client/openapi_client/models/job_queue_execution_mode.py +101 -0
- anyscale/client/openapi_client/models/job_queue_spec.py +263 -0
- anyscale/client/openapi_client/models/job_queue_state.py +100 -0
- anyscale/client/openapi_client/models/job_queues_query.py +262 -0
- anyscale/client/openapi_client/models/job_run_type.py +101 -0
- anyscale/client/openapi_client/models/job_state_log_level_types.py +100 -0
- anyscale/client/openapi_client/models/job_status.py +105 -0
- anyscale/client/openapi_client/models/job_submissions_sort_field.py +101 -0
- anyscale/client/openapi_client/models/jobqueue_response.py +121 -0
- anyscale/client/openapi_client/models/jobs_logs.py +152 -0
- anyscale/client/openapi_client/models/jobs_logs_query_info.py +181 -0
- anyscale/client/openapi_client/models/jobs_sort_field.py +104 -0
- anyscale/client/openapi_client/models/jobslogs_response.py +121 -0
- anyscale/client/openapi_client/models/jobslogsqueryinfo_response.py +121 -0
- anyscale/client/openapi_client/models/json_patch_operation.py +200 -0
- anyscale/client/openapi_client/models/kubernetes_manager_registration_request.py +123 -0
- anyscale/client/openapi_client/models/kubernetes_manager_registration_response.py +123 -0
- anyscale/client/openapi_client/models/kubernetesmanagerregistrationresponse_response.py +121 -0
- anyscale/client/openapi_client/models/lb_resource.py +123 -0
- anyscale/client/openapi_client/models/lbresource_response.py +121 -0
- anyscale/client/openapi_client/models/list_machine_pools_response.py +123 -0
- anyscale/client/openapi_client/models/list_machines_response.py +121 -0
- anyscale/client/openapi_client/models/list_resource_quotas_query.py +234 -0
- anyscale/client/openapi_client/models/list_response_metadata.py +146 -0
- anyscale/client/openapi_client/models/listmachinepoolsresponse_response.py +121 -0
- anyscale/client/openapi_client/models/listmachinesresponse_response.py +121 -0
- anyscale/client/openapi_client/models/log_detail.py +187 -0
- anyscale/client/openapi_client/models/log_details.py +151 -0
- anyscale/client/openapi_client/models/log_download_config.py +206 -0
- anyscale/client/openapi_client/models/log_download_request.py +150 -0
- anyscale/client/openapi_client/models/log_download_result.py +207 -0
- anyscale/client/openapi_client/models/log_file_chunk.py +439 -0
- anyscale/client/openapi_client/models/log_filter.py +430 -0
- anyscale/client/openapi_client/models/log_item.py +181 -0
- anyscale/client/openapi_client/models/log_item_batch.py +151 -0
- anyscale/client/openapi_client/models/log_level_types.py +100 -0
- anyscale/client/openapi_client/models/log_stream.py +151 -0
- anyscale/client/openapi_client/models/logdetails_response.py +121 -0
- anyscale/client/openapi_client/models/logdownloadresult_response.py +121 -0
- anyscale/client/openapi_client/models/login_user_params.py +205 -0
- anyscale/client/openapi_client/models/logitembatch_response.py +121 -0
- anyscale/client/openapi_client/models/logs_output.py +202 -0
- anyscale/client/openapi_client/models/logsoutput_response.py +121 -0
- anyscale/client/openapi_client/models/logstream_response.py +121 -0
- anyscale/client/openapi_client/models/long_running_workload.py +256 -0
- anyscale/client/openapi_client/models/longrunningworkload_list_response.py +147 -0
- anyscale/client/openapi_client/models/machine_allocation_state.py +100 -0
- anyscale/client/openapi_client/models/machine_connection_state.py +100 -0
- anyscale/client/openapi_client/models/machine_info.py +466 -0
- anyscale/client/openapi_client/models/machine_pool.py +266 -0
- anyscale/client/openapi_client/models/metronome_customer_info_model.py +148 -0
- anyscale/client/openapi_client/models/metronome_dashboard_type.py +101 -0
- anyscale/client/openapi_client/models/metronomecustomerinfomodel_list_response.py +147 -0
- anyscale/client/openapi_client/models/metronomecustomerinfomodel_response.py +121 -0
- anyscale/client/openapi_client/models/mini_build.py +267 -0
- anyscale/client/openapi_client/models/mini_cloud.py +321 -0
- anyscale/client/openapi_client/models/mini_cluster.py +148 -0
- anyscale/client/openapi_client/models/mini_compute_template.py +228 -0
- anyscale/client/openapi_client/models/mini_compute_template_config.py +121 -0
- anyscale/client/openapi_client/models/mini_job_run.py +599 -0
- anyscale/client/openapi_client/models/mini_namespace.py +148 -0
- anyscale/client/openapi_client/models/mini_organization.py +148 -0
- anyscale/client/openapi_client/models/mini_production_job.py +202 -0
- anyscale/client/openapi_client/models/mini_project.py +205 -0
- anyscale/client/openapi_client/models/mini_runtime_environment.py +147 -0
- anyscale/client/openapi_client/models/mini_schedule.py +180 -0
- anyscale/client/openapi_client/models/mini_user.py +266 -0
- anyscale/client/openapi_client/models/minibuild_list_response.py +147 -0
- anyscale/client/openapi_client/models/minicomputetemplate_list_response.py +147 -0
- anyscale/client/openapi_client/models/miniproject_list_response.py +147 -0
- anyscale/client/openapi_client/models/monitor_logs_extension.py +100 -0
- anyscale/client/openapi_client/models/named_entity.py +148 -0
- anyscale/client/openapi_client/models/nfs_mount_target.py +151 -0
- anyscale/client/openapi_client/models/node_registration_aws.py +152 -0
- anyscale/client/openapi_client/models/node_registration_gcp.py +123 -0
- anyscale/client/openapi_client/models/node_registration_k8_s.py +178 -0
- anyscale/client/openapi_client/models/node_registration_provisioned.py +150 -0
- anyscale/client/openapi_client/models/node_registration_v2.py +279 -0
- anyscale/client/openapi_client/models/node_type.py +100 -0
- anyscale/client/openapi_client/models/notification_channel_email_config.py +121 -0
- anyscale/client/openapi_client/models/notification_channel_webhook_config.py +121 -0
- anyscale/client/openapi_client/models/onboarding_user_cards_query.py +122 -0
- anyscale/client/openapi_client/models/organization.py +490 -0
- anyscale/client/openapi_client/models/organization_availability.py +148 -0
- anyscale/client/openapi_client/models/organization_collaborator.py +259 -0
- anyscale/client/openapi_client/models/organization_configuration.py +280 -0
- anyscale/client/openapi_client/models/organization_configuration_response.py +227 -0
- anyscale/client/openapi_client/models/organization_invitation.py +255 -0
- anyscale/client/openapi_client/models/organization_invitation_base.py +121 -0
- anyscale/client/openapi_client/models/organization_marketing_questions.py +198 -0
- anyscale/client/openapi_client/models/organization_permission_level.py +100 -0
- anyscale/client/openapi_client/models/organization_project_collaborator.py +175 -0
- anyscale/client/openapi_client/models/organization_project_collaborator_value.py +148 -0
- anyscale/client/openapi_client/models/organization_public_identifier.py +121 -0
- anyscale/client/openapi_client/models/organization_response.py +121 -0
- anyscale/client/openapi_client/models/organization_summary.py +229 -0
- anyscale/client/openapi_client/models/organization_usage_alert.py +210 -0
- anyscale/client/openapi_client/models/organization_usage_alert_severity.py +100 -0
- anyscale/client/openapi_client/models/organizationavailability_response.py +121 -0
- anyscale/client/openapi_client/models/organizationcollaborator_list_response.py +147 -0
- anyscale/client/openapi_client/models/organizationconfiguration_list_response.py +147 -0
- anyscale/client/openapi_client/models/organizationconfigurationresponse_response.py +121 -0
- anyscale/client/openapi_client/models/organizationinvitation_list_response.py +147 -0
- anyscale/client/openapi_client/models/organizationinvitation_response.py +121 -0
- anyscale/client/openapi_client/models/organizationinvitationbase_response.py +121 -0
- anyscale/client/openapi_client/models/organizationprojectcollaborator_list_response.py +147 -0
- anyscale/client/openapi_client/models/organizationpublicidentifier_response.py +121 -0
- anyscale/client/openapi_client/models/organizationusagealert_list_response.py +147 -0
- anyscale/client/openapi_client/models/page_query.py +153 -0
- anyscale/client/openapi_client/models/pause_schedule.py +123 -0
- anyscale/client/openapi_client/models/permission_level.py +101 -0
- anyscale/client/openapi_client/models/platform_fine_tuning_job.py +577 -0
- anyscale/client/openapi_client/models/platformfinetuningjob_list_response.py +147 -0
- anyscale/client/openapi_client/models/platformfinetuningjob_response.py +121 -0
- anyscale/client/openapi_client/models/product_autoscaler_flag.py +122 -0
- anyscale/client/openapi_client/models/product_type.py +100 -0
- anyscale/client/openapi_client/models/productautoscalerflag_response.py +121 -0
- anyscale/client/openapi_client/models/production_job.py +437 -0
- anyscale/client/openapi_client/models/production_job_config.py +348 -0
- anyscale/client/openapi_client/models/production_job_event.py +378 -0
- anyscale/client/openapi_client/models/production_job_event_scope_filter.py +101 -0
- anyscale/client/openapi_client/models/production_job_state_transition.py +293 -0
- anyscale/client/openapi_client/models/productionjob_response.py +121 -0
- anyscale/client/openapi_client/models/productionjobevent_list_response.py +147 -0
- anyscale/client/openapi_client/models/project.py +554 -0
- anyscale/client/openapi_client/models/project_base.py +121 -0
- anyscale/client/openapi_client/models/project_collaborator.py +175 -0
- anyscale/client/openapi_client/models/project_collaborator_value.py +175 -0
- anyscale/client/openapi_client/models/project_collaborators_put_message.py +121 -0
- anyscale/client/openapi_client/models/project_create_message.py +148 -0
- anyscale/client/openapi_client/models/project_default_session_name.py +121 -0
- anyscale/client/openapi_client/models/project_delete_message.py +121 -0
- anyscale/client/openapi_client/models/project_list_response.py +147 -0
- anyscale/client/openapi_client/models/project_patch_message.py +121 -0
- anyscale/client/openapi_client/models/project_response.py +121 -0
- anyscale/client/openapi_client/models/projectbase_response.py +121 -0
- anyscale/client/openapi_client/models/projectcollaborator_list_response.py +147 -0
- anyscale/client/openapi_client/models/projectdefaultsessionname_response.py +121 -0
- anyscale/client/openapi_client/models/projects_sort_field.py +101 -0
- anyscale/client/openapi_client/models/projects_violating_tree_hierarchy_response.py +121 -0
- anyscale/client/openapi_client/models/projectsviolatingtreehierarchyresponse_response.py +121 -0
- anyscale/client/openapi_client/models/protocols.py +150 -0
- anyscale/client/openapi_client/models/provider_metadata.py +205 -0
- anyscale/client/openapi_client/models/providermetadata_response.py +121 -0
- anyscale/client/openapi_client/models/python_modules.py +150 -0
- anyscale/client/openapi_client/models/quota.py +198 -0
- anyscale/client/openapi_client/models/ray_gcs_external_storage_config.py +178 -0
- anyscale/client/openapi_client/models/ray_runtime_env_config.py +262 -0
- anyscale/client/openapi_client/models/read_billing_version.py +210 -0
- anyscale/client/openapi_client/models/readbillingversion_list_response.py +147 -0
- anyscale/client/openapi_client/models/replica_details.py +152 -0
- anyscale/client/openapi_client/models/replica_state.py +104 -0
- anyscale/client/openapi_client/models/request_email_magic_link_response.py +147 -0
- anyscale/client/openapi_client/models/request_otp_return_api_model.py +148 -0
- anyscale/client/openapi_client/models/request_password_reset_params.py +147 -0
- anyscale/client/openapi_client/models/requestemailmagiclinkresponse_response.py +121 -0
- anyscale/client/openapi_client/models/requestotpreturnapimodel_response.py +121 -0
- anyscale/client/openapi_client/models/reset_password_params.py +148 -0
- anyscale/client/openapi_client/models/resource_quota.py +465 -0
- anyscale/client/openapi_client/models/resource_quota_status.py +123 -0
- anyscale/client/openapi_client/models/resourcequota_list_response.py +147 -0
- anyscale/client/openapi_client/models/resourcequota_response.py +121 -0
- anyscale/client/openapi_client/models/resources.py +234 -0
- anyscale/client/openapi_client/models/resubmit_ft_job_request.py +121 -0
- anyscale/client/openapi_client/models/rollback_service_model.py +122 -0
- anyscale/client/openapi_client/models/rollout_strategy.py +100 -0
- anyscale/client/openapi_client/models/s3_download_location.py +148 -0
- anyscale/client/openapi_client/models/schedule_config.py +151 -0
- anyscale/client/openapi_client/models/serve_deployment_grafana_dashboard_status.py +101 -0
- anyscale/client/openapi_client/models/serve_deployment_logs.py +152 -0
- anyscale/client/openapi_client/models/serve_deployment_state.py +104 -0
- anyscale/client/openapi_client/models/servedeploymentlogs_response.py +121 -0
- anyscale/client/openapi_client/models/server_session_token.py +121 -0
- anyscale/client/openapi_client/models/serversessiontoken_response.py +121 -0
- anyscale/client/openapi_client/models/service_config.py +178 -0
- anyscale/client/openapi_client/models/service_event_current_state.py +108 -0
- anyscale/client/openapi_client/models/service_event_level.py +102 -0
- anyscale/client/openapi_client/models/service_event_origin.py +103 -0
- anyscale/client/openapi_client/models/service_event_scope.py +103 -0
- anyscale/client/openapi_client/models/service_event_scope_filter.py +104 -0
- anyscale/client/openapi_client/models/service_event_type.py +125 -0
- anyscale/client/openapi_client/models/service_event_verbose_message_model.py +180 -0
- anyscale/client/openapi_client/models/service_goal_states.py +100 -0
- anyscale/client/openapi_client/models/service_observability_urls.py +206 -0
- anyscale/client/openapi_client/models/service_sort_field.py +101 -0
- anyscale/client/openapi_client/models/service_type.py +100 -0
- anyscale/client/openapi_client/models/service_usage.py +353 -0
- anyscale/client/openapi_client/models/service_version_state.py +106 -0
- anyscale/client/openapi_client/models/serviceeventverbosemessagemodel_list_response.py +147 -0
- anyscale/client/openapi_client/models/session.py +834 -0
- anyscale/client/openapi_client/models/session_access.py +102 -0
- anyscale/client/openapi_client/models/session_autosync_sessions_update_message.py +121 -0
- anyscale/client/openapi_client/models/session_command.py +413 -0
- anyscale/client/openapi_client/models/session_command_finish_options.py +226 -0
- anyscale/client/openapi_client/models/session_command_id.py +121 -0
- anyscale/client/openapi_client/models/session_command_types.py +100 -0
- anyscale/client/openapi_client/models/session_create_message.py +148 -0
- anyscale/client/openapi_client/models/session_delete_message.py +121 -0
- anyscale/client/openapi_client/models/session_describe.py +175 -0
- anyscale/client/openapi_client/models/session_details.py +148 -0
- anyscale/client/openapi_client/models/session_event.py +267 -0
- anyscale/client/openapi_client/models/session_event_cause.py +150 -0
- anyscale/client/openapi_client/models/session_event_types.py +111 -0
- anyscale/client/openapi_client/models/session_execute_message.py +121 -0
- anyscale/client/openapi_client/models/session_finish_command_message.py +175 -0
- anyscale/client/openapi_client/models/session_history_item.py +146 -0
- anyscale/client/openapi_client/models/session_kill_command_message.py +121 -0
- anyscale/client/openapi_client/models/session_list_response.py +147 -0
- anyscale/client/openapi_client/models/session_patch_message.py +121 -0
- anyscale/client/openapi_client/models/session_response.py +121 -0
- anyscale/client/openapi_client/models/session_ssh_key.py +148 -0
- anyscale/client/openapi_client/models/session_starting_up_data.py +146 -0
- anyscale/client/openapi_client/models/session_state.py +111 -0
- anyscale/client/openapi_client/models/session_state_change_message.py +121 -0
- anyscale/client/openapi_client/models/session_state_data.py +146 -0
- anyscale/client/openapi_client/models/session_stopping_data.py +146 -0
- anyscale/client/openapi_client/models/sessioncommand_list_response.py +147 -0
- anyscale/client/openapi_client/models/sessioncommandid_response.py +121 -0
- anyscale/client/openapi_client/models/sessiondescribe_response.py +121 -0
- anyscale/client/openapi_client/models/sessiondetails_response.py +121 -0
- anyscale/client/openapi_client/models/sessionevent_list_response.py +147 -0
- anyscale/client/openapi_client/models/sessionhistoryitem_list_response.py +147 -0
- anyscale/client/openapi_client/models/sessions_sort_field.py +104 -0
- anyscale/client/openapi_client/models/sessionsshkey_response.py +121 -0
- anyscale/client/openapi_client/models/setup_initialize_session_options.py +225 -0
- anyscale/client/openapi_client/models/show_otp_source_return_api_model.py +121 -0
- anyscale/client/openapi_client/models/showotpsourcereturnapimodel_response.py +121 -0
- anyscale/client/openapi_client/models/snapshot_create_message.py +148 -0
- anyscale/client/openapi_client/models/snapshot_delete_message.py +148 -0
- anyscale/client/openapi_client/models/snapshot_patch_message.py +148 -0
- anyscale/client/openapi_client/models/socket_message_schemas.py +499 -0
- anyscale/client/openapi_client/models/socket_message_types.py +113 -0
- anyscale/client/openapi_client/models/socketmessageschemas_response.py +121 -0
- anyscale/client/openapi_client/models/socketmessagetypes_response.py +121 -0
- anyscale/client/openapi_client/models/sort_order.py +100 -0
- anyscale/client/openapi_client/models/sso_login_info.py +151 -0
- anyscale/client/openapi_client/models/ssologininfo_response.py +121 -0
- anyscale/client/openapi_client/models/start_session_options.py +146 -0
- anyscale/client/openapi_client/models/stop_session_options.py +227 -0
- anyscale/client/openapi_client/models/stream_publish_request.py +239 -0
- anyscale/client/openapi_client/models/subnet_id_with_availability_zone_aws.py +148 -0
- anyscale/client/openapi_client/models/support_requests_query.py +178 -0
- anyscale/client/openapi_client/models/supportedbaseimagesenum.py +1570 -0
- anyscale/client/openapi_client/models/templatized_compute_configs.py +202 -0
- anyscale/client/openapi_client/models/templatized_decorated_application_templates.py +202 -0
- anyscale/client/openapi_client/models/templatizedcomputeconfigs_response.py +121 -0
- anyscale/client/openapi_client/models/templatizeddecoratedapplicationtemplates_response.py +121 -0
- anyscale/client/openapi_client/models/text_query.py +178 -0
- anyscale/client/openapi_client/models/timestamped_logs_output.py +148 -0
- anyscale/client/openapi_client/models/timestampedlogsoutput_response.py +121 -0
- anyscale/client/openapi_client/models/tool.py +100 -0
- anyscale/client/openapi_client/models/tracing_config.py +178 -0
- anyscale/client/openapi_client/models/try_login_email_response.py +208 -0
- anyscale/client/openapi_client/models/tryloginemailresponse_response.py +121 -0
- anyscale/client/openapi_client/models/unified_job_sort_field.py +103 -0
- anyscale/client/openapi_client/models/unified_job_status.py +114 -0
- anyscale/client/openapi_client/models/unified_job_type.py +100 -0
- anyscale/client/openapi_client/models/update_cloud_with_cloud_resource.py +178 -0
- anyscale/client/openapi_client/models/update_cloud_with_cloud_resource_gcp.py +178 -0
- anyscale/client/openapi_client/models/update_cluster_dns.py +152 -0
- anyscale/client/openapi_client/models/update_compute_template.py +146 -0
- anyscale/client/openapi_client/models/update_compute_template_config.py +464 -0
- anyscale/client/openapi_client/models/update_endpoint.py +152 -0
- anyscale/client/openapi_client/models/update_machine_pool_request.py +151 -0
- anyscale/client/openapi_client/models/update_model_deployment.py +152 -0
- anyscale/client/openapi_client/models/update_organization_collaborator.py +121 -0
- anyscale/client/openapi_client/models/update_project_collaborator.py +121 -0
- anyscale/client/openapi_client/models/update_resource_quota.py +122 -0
- anyscale/client/openapi_client/models/updatemachinepoolresponse_response.py +121 -0
- anyscale/client/openapi_client/models/upload_session_command_logs_locations.py +148 -0
- anyscale/client/openapi_client/models/uploadsessioncommandlogslocations_response.py +121 -0
- anyscale/client/openapi_client/models/user_info.py +569 -0
- anyscale/client/openapi_client/models/user_resend_email_options.py +147 -0
- anyscale/client/openapi_client/models/user_service_access_types.py +100 -0
- anyscale/client/openapi_client/models/userinfo_response.py +121 -0
- anyscale/client/openapi_client/models/utm_fields.py +224 -0
- anyscale/client/openapi_client/models/ux_instance.py +468 -0
- anyscale/client/openapi_client/models/validate_otp_params_api_model.py +121 -0
- anyscale/client/openapi_client/models/validation_error.py +175 -0
- anyscale/client/openapi_client/models/verify_response.py +147 -0
- anyscale/client/openapi_client/models/verifyresponse_response.py +121 -0
- anyscale/client/openapi_client/models/visibility.py +100 -0
- anyscale/client/openapi_client/models/waitlist_status_response.py +121 -0
- anyscale/client/openapi_client/models/waitlist_status_type.py +100 -0
- anyscale/client/openapi_client/models/waitliststatusresponse_response.py +121 -0
- anyscale/client/openapi_client/models/wand_b_run_details.py +147 -0
- anyscale/client/openapi_client/models/web_terminal.py +121 -0
- anyscale/client/openapi_client/models/webterminal_list_response.py +147 -0
- anyscale/client/openapi_client/models/webterminal_response.py +121 -0
- anyscale/client/openapi_client/models/worker_node_type.py +404 -0
- anyscale/client/openapi_client/models/workload_type.py +102 -0
- anyscale/client/openapi_client/models/workspace_dataplane_artifact.py +181 -0
- anyscale/client/openapi_client/models/workspace_dataplane_artifacts.py +123 -0
- anyscale/client/openapi_client/models/workspace_dataplane_proxied_artifacts.py +178 -0
- anyscale/client/openapi_client/models/workspace_event.py +325 -0
- anyscale/client/openapi_client/models/workspace_event_source.py +100 -0
- anyscale/client/openapi_client/models/workspace_event_source_filter.py +101 -0
- anyscale/client/openapi_client/models/workspace_readme.py +123 -0
- anyscale/client/openapi_client/models/workspace_snapshot_states.py +108 -0
- anyscale/client/openapi_client/models/workspace_template.py +353 -0
- anyscale/client/openapi_client/models/workspace_template_cluster_environment_metadata.py +178 -0
- anyscale/client/openapi_client/models/workspacedataplaneartifacts_response.py +121 -0
- anyscale/client/openapi_client/models/workspacedataplaneproxiedartifacts_response.py +121 -0
- anyscale/client/openapi_client/models/workspaceevent_list_response.py +147 -0
- anyscale/client/openapi_client/models/workspacereadme_response.py +121 -0
- anyscale/client/openapi_client/models/workspacetemplate_list_response.py +147 -0
- anyscale/client/openapi_client/models/workspacetemplateclusterenvironmentmetadata_response.py +121 -0
- anyscale/client/openapi_client/models/write_cloud.py +546 -0
- anyscale/client/openapi_client/models/write_cluster_config.py +123 -0
- anyscale/client/openapi_client/models/write_project.py +226 -0
- anyscale/client/openapi_client/models/write_session.py +147 -0
- anyscale/client/openapi_client/models/write_support_request.py +121 -0
- anyscale/client/openapi_client/rest.py +296 -0
- anyscale/client/requirements.txt +6 -0
- anyscale/client/setup.cfg +2 -0
- anyscale/client/setup.py +40 -0
- anyscale/client/test-requirements.txt +3 -0
- anyscale/client/tox.ini +9 -0
- anyscale/cloud.py +216 -0
- anyscale/cloud_resource.py +1032 -0
- anyscale/cluster.py +138 -0
- anyscale/cluster_compute.py +167 -0
- anyscale/cluster_env.py +173 -0
- anyscale/commands/__init__.py +0 -0
- anyscale/commands/aggregated_instance_usage_commands.py +86 -0
- anyscale/commands/anyscale_api/__init__.py +0 -0
- anyscale/commands/anyscale_api/api_commands.py +23 -0
- anyscale/commands/anyscale_api/session_commands_commands.py +80 -0
- anyscale/commands/anyscale_api/session_operations_commands.py +28 -0
- anyscale/commands/anyscale_api/sessions_commands.py +152 -0
- anyscale/commands/auth_commands.py +41 -0
- anyscale/commands/cloud_commands.py +1011 -0
- anyscale/commands/cloud_commands_util.py +10 -0
- anyscale/commands/cluster_commands.py +476 -0
- anyscale/commands/cluster_env_commands.py +139 -0
- anyscale/commands/command_examples.py +495 -0
- anyscale/commands/compute_config_commands.py +252 -0
- anyscale/commands/config_commands.py +213 -0
- anyscale/commands/exec_commands.py +14 -0
- anyscale/commands/experimental_integrations_commands.py +70 -0
- anyscale/commands/image_commands.py +125 -0
- anyscale/commands/job_commands.py +745 -0
- anyscale/commands/list_commands.py +85 -0
- anyscale/commands/llm/dataset_commands.py +269 -0
- anyscale/commands/llm/group.py +15 -0
- anyscale/commands/llm/models_commands.py +123 -0
- anyscale/commands/login_commands.py +79 -0
- anyscale/commands/logs_commands.py +312 -0
- anyscale/commands/machine_commands.py +116 -0
- anyscale/commands/machine_pool_commands.py +163 -0
- anyscale/commands/migrate_commands.py +84 -0
- anyscale/commands/project_commands.py +203 -0
- anyscale/commands/resource_quota_commands.py +214 -0
- anyscale/commands/schedule_commands.py +436 -0
- anyscale/commands/service_account_commands.py +72 -0
- anyscale/commands/service_commands.py +738 -0
- anyscale/commands/session_commands_hidden.py +179 -0
- anyscale/commands/util.py +152 -0
- anyscale/commands/workspace_commands.py +511 -0
- anyscale/commands/workspace_commands_v2.py +874 -0
- anyscale/component_activity_util.py +83 -0
- anyscale/compute_config/__init__.py +84 -0
- anyscale/compute_config/_private/compute_config_sdk.py +433 -0
- anyscale/compute_config/commands.py +122 -0
- anyscale/compute_config/models.py +630 -0
- anyscale/conf.py +23 -0
- anyscale/connect.py +1323 -0
- anyscale/connect_utils/__init__.py +0 -0
- anyscale/connect_utils/prepare_cluster.py +962 -0
- anyscale/connect_utils/project.py +298 -0
- anyscale/connect_utils/start_interactive_session.py +437 -0
- anyscale/controllers/__init__.py +0 -0
- anyscale/controllers/auth_controller.py +134 -0
- anyscale/controllers/base_controller.py +52 -0
- anyscale/controllers/cloud_controller.py +3609 -0
- anyscale/controllers/cloud_functional_verification_controller.py +858 -0
- anyscale/controllers/cluster_controller.py +720 -0
- anyscale/controllers/cluster_env_controller.py +219 -0
- anyscale/controllers/compute_config_controller.py +351 -0
- anyscale/controllers/config_controller.py +422 -0
- anyscale/controllers/experimental_integrations_controller.py +80 -0
- anyscale/controllers/job_controller.py +647 -0
- anyscale/controllers/jobs_bg_controller.py +0 -0
- anyscale/controllers/list_controller.py +290 -0
- anyscale/controllers/llm/__init__.py +0 -0
- anyscale/controllers/llm/models_controller.py +144 -0
- anyscale/controllers/logs_controller.py +449 -0
- anyscale/controllers/machine_controller.py +37 -0
- anyscale/controllers/machine_pool_controller.py +86 -0
- anyscale/controllers/project_controller.py +281 -0
- anyscale/controllers/resource_quota_controller.py +183 -0
- anyscale/controllers/schedule_controller.py +333 -0
- anyscale/controllers/service_account_controller.py +168 -0
- anyscale/controllers/service_controller.py +453 -0
- anyscale/controllers/workspace_controller.py +253 -0
- anyscale/feature_flags.py +4 -0
- anyscale/fingerprint.py +62 -0
- anyscale/formatters/__init__.py +0 -0
- anyscale/formatters/clouds_formatter.py +65 -0
- anyscale/formatters/common_formatter.py +22 -0
- anyscale/gcp_verification.py +792 -0
- anyscale/image/__init__.py +73 -0
- anyscale/image/_private/image_sdk.py +202 -0
- anyscale/image/commands.py +117 -0
- anyscale/image/models.py +57 -0
- anyscale/integrations.py +329 -0
- anyscale/job/__init__.py +166 -0
- anyscale/job/_private/job_sdk.py +497 -0
- anyscale/job/commands.py +267 -0
- anyscale/job/models.py +500 -0
- anyscale/links.py +4 -0
- anyscale/llm/__init__.py +2 -0
- anyscale/llm/dataset/__init__.py +2 -0
- anyscale/llm/dataset/_private/__init__.py +0 -0
- anyscale/llm/dataset/_private/docs.py +63 -0
- anyscale/llm/dataset/_private/models.py +71 -0
- anyscale/llm/dataset/_private/sdk.py +147 -0
- anyscale/llm/model/__init__.py +2 -0
- anyscale/llm/model/_private/models_sdk.py +62 -0
- anyscale/llm/model/commands.py +93 -0
- anyscale/llm/model/models.py +171 -0
- anyscale/llm/model/sdk.py +62 -0
- anyscale/llm/sdk.py +27 -0
- anyscale/memorydb_supported_zones.json +22 -0
- anyscale/models/job_model.py +457 -0
- anyscale/models/service_model.py +125 -0
- anyscale/project.py +501 -0
- anyscale/schedule/__init__.py +91 -0
- anyscale/schedule/_private/schedule_sdk.py +165 -0
- anyscale/schedule/commands.py +149 -0
- anyscale/schedule/models.py +145 -0
- anyscale/scripts.py +164 -0
- anyscale/sdk/anyscale_client/__init__.py +235 -0
- anyscale/sdk/anyscale_client/api/__init__.py +6 -0
- anyscale/sdk/anyscale_client/api/default_api.py +11625 -0
- anyscale/sdk/anyscale_client/api_client.py +647 -0
- anyscale/sdk/anyscale_client/configuration.py +373 -0
- anyscale/sdk/anyscale_client/exceptions.py +120 -0
- anyscale/sdk/anyscale_client/models/__init__.py +220 -0
- anyscale/sdk/anyscale_client/models/access_config.py +122 -0
- anyscale/sdk/anyscale_client/models/app_config.py +436 -0
- anyscale/sdk/anyscale_client/models/app_config_config_schema.py +235 -0
- anyscale/sdk/anyscale_client/models/appconfig_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/appconfig_response.py +121 -0
- anyscale/sdk/anyscale_client/models/apply_production_service_v2_model.py +490 -0
- anyscale/sdk/anyscale_client/models/apply_service_model.py +490 -0
- anyscale/sdk/anyscale_client/models/archive_status.py +101 -0
- anyscale/sdk/anyscale_client/models/base_job_status.py +105 -0
- anyscale/sdk/anyscale_client/models/baseimagesenum.py +2130 -0
- anyscale/sdk/anyscale_client/models/build.py +607 -0
- anyscale/sdk/anyscale_client/models/build_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/build_log_response.py +123 -0
- anyscale/sdk/anyscale_client/models/build_response.py +121 -0
- anyscale/sdk/anyscale_client/models/build_status.py +104 -0
- anyscale/sdk/anyscale_client/models/buildlogresponse_response.py +121 -0
- anyscale/sdk/anyscale_client/models/cloud.py +802 -0
- anyscale/sdk/anyscale_client/models/cloud_config.py +206 -0
- anyscale/sdk/anyscale_client/models/cloud_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/cloud_providers.py +103 -0
- anyscale/sdk/anyscale_client/models/cloud_response.py +121 -0
- anyscale/sdk/anyscale_client/models/cloud_state.py +104 -0
- anyscale/sdk/anyscale_client/models/cloud_status.py +100 -0
- anyscale/sdk/anyscale_client/models/cloud_type.py +100 -0
- anyscale/sdk/anyscale_client/models/cloud_types.py +100 -0
- anyscale/sdk/anyscale_client/models/cloud_version.py +100 -0
- anyscale/sdk/anyscale_client/models/clouds_query.py +150 -0
- anyscale/sdk/anyscale_client/models/cluster.py +721 -0
- anyscale/sdk/anyscale_client/models/cluster_compute.py +415 -0
- anyscale/sdk/anyscale_client/models/cluster_compute_config.py +461 -0
- anyscale/sdk/anyscale_client/models/cluster_computes_query.py +293 -0
- anyscale/sdk/anyscale_client/models/cluster_environment.py +380 -0
- anyscale/sdk/anyscale_client/models/cluster_environment_build.py +578 -0
- anyscale/sdk/anyscale_client/models/cluster_environment_build_log_response.py +123 -0
- anyscale/sdk/anyscale_client/models/cluster_environment_build_operation.py +237 -0
- anyscale/sdk/anyscale_client/models/cluster_environment_build_status.py +104 -0
- anyscale/sdk/anyscale_client/models/cluster_environments_query.py +290 -0
- anyscale/sdk/anyscale_client/models/cluster_head_node_info.py +152 -0
- anyscale/sdk/anyscale_client/models/cluster_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/cluster_management_stack_versions.py +100 -0
- anyscale/sdk/anyscale_client/models/cluster_operation.py +266 -0
- anyscale/sdk/anyscale_client/models/cluster_operation_type.py +101 -0
- anyscale/sdk/anyscale_client/models/cluster_response.py +121 -0
- anyscale/sdk/anyscale_client/models/cluster_services_urls.py +430 -0
- anyscale/sdk/anyscale_client/models/cluster_state.py +108 -0
- anyscale/sdk/anyscale_client/models/cluster_status.py +104 -0
- anyscale/sdk/anyscale_client/models/cluster_status_details.py +100 -0
- anyscale/sdk/anyscale_client/models/clustercompute_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/clustercompute_response.py +121 -0
- anyscale/sdk/anyscale_client/models/clusterenvironment_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/clusterenvironment_response.py +121 -0
- anyscale/sdk/anyscale_client/models/clusterenvironmentbuild_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/clusterenvironmentbuild_response.py +121 -0
- anyscale/sdk/anyscale_client/models/clusterenvironmentbuildlogresponse_response.py +121 -0
- anyscale/sdk/anyscale_client/models/clusterenvironmentbuildoperation_response.py +121 -0
- anyscale/sdk/anyscale_client/models/clusteroperation_response.py +121 -0
- anyscale/sdk/anyscale_client/models/clusters_query.py +234 -0
- anyscale/sdk/anyscale_client/models/compute_node_type.py +292 -0
- anyscale/sdk/anyscale_client/models/compute_stack.py +100 -0
- anyscale/sdk/anyscale_client/models/compute_template.py +415 -0
- anyscale/sdk/anyscale_client/models/compute_template_config.py +461 -0
- anyscale/sdk/anyscale_client/models/compute_template_query.py +316 -0
- anyscale/sdk/anyscale_client/models/computetemplate_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/computetemplate_response.py +121 -0
- anyscale/sdk/anyscale_client/models/computetemplateconfig_response.py +121 -0
- anyscale/sdk/anyscale_client/models/create_app_config.py +235 -0
- anyscale/sdk/anyscale_client/models/create_app_config_configuration_schema.py +235 -0
- anyscale/sdk/anyscale_client/models/create_build.py +263 -0
- anyscale/sdk/anyscale_client/models/create_byod_app_config_configuration_schema.py +206 -0
- anyscale/sdk/anyscale_client/models/create_byod_cluster_environment.py +180 -0
- anyscale/sdk/anyscale_client/models/create_byod_cluster_environment_build.py +152 -0
- anyscale/sdk/anyscale_client/models/create_byod_cluster_environment_configuration_schema.py +208 -0
- anyscale/sdk/anyscale_client/models/create_cloud.py +518 -0
- anyscale/sdk/anyscale_client/models/create_cluster.py +376 -0
- anyscale/sdk/anyscale_client/models/create_cluster_compute.py +229 -0
- anyscale/sdk/anyscale_client/models/create_cluster_compute_config.py +463 -0
- anyscale/sdk/anyscale_client/models/create_cluster_environment.py +235 -0
- anyscale/sdk/anyscale_client/models/create_cluster_environment_build.py +263 -0
- anyscale/sdk/anyscale_client/models/create_cluster_environment_configuration_schema.py +235 -0
- anyscale/sdk/anyscale_client/models/create_compute_template.py +229 -0
- anyscale/sdk/anyscale_client/models/create_compute_template_config.py +464 -0
- anyscale/sdk/anyscale_client/models/create_job_queue_config.py +206 -0
- anyscale/sdk/anyscale_client/models/create_production_job.py +234 -0
- anyscale/sdk/anyscale_client/models/create_production_job_config.py +347 -0
- anyscale/sdk/anyscale_client/models/create_project.py +207 -0
- anyscale/sdk/anyscale_client/models/create_schedule.py +263 -0
- anyscale/sdk/anyscale_client/models/create_session.py +432 -0
- anyscale/sdk/anyscale_client/models/create_session_command.py +152 -0
- anyscale/sdk/anyscale_client/models/create_sso_config.py +150 -0
- anyscale/sdk/anyscale_client/models/grpc_protocol_config.py +178 -0
- anyscale/sdk/anyscale_client/models/ha_job_goal_states.py +102 -0
- anyscale/sdk/anyscale_client/models/ha_job_states.py +109 -0
- anyscale/sdk/anyscale_client/models/http_protocol_config.py +150 -0
- anyscale/sdk/anyscale_client/models/http_validation_error.py +120 -0
- anyscale/sdk/anyscale_client/models/idle_termination_status.py +104 -0
- anyscale/sdk/anyscale_client/models/job.py +466 -0
- anyscale/sdk/anyscale_client/models/job_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/job_queue_config.py +122 -0
- anyscale/sdk/anyscale_client/models/job_queue_execution_mode.py +101 -0
- anyscale/sdk/anyscale_client/models/job_queue_spec.py +263 -0
- anyscale/sdk/anyscale_client/models/job_run_type.py +101 -0
- anyscale/sdk/anyscale_client/models/job_status.py +105 -0
- anyscale/sdk/anyscale_client/models/jobs_query.py +458 -0
- anyscale/sdk/anyscale_client/models/jobs_sort_field.py +104 -0
- anyscale/sdk/anyscale_client/models/list_response_metadata.py +146 -0
- anyscale/sdk/anyscale_client/models/list_service_model.py +347 -0
- anyscale/sdk/anyscale_client/models/listservicemodel_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/log_download_result.py +207 -0
- anyscale/sdk/anyscale_client/models/log_file_chunk.py +439 -0
- anyscale/sdk/anyscale_client/models/log_level_types.py +100 -0
- anyscale/sdk/anyscale_client/models/log_stream.py +151 -0
- anyscale/sdk/anyscale_client/models/logdownloadresult_response.py +121 -0
- anyscale/sdk/anyscale_client/models/logstream_response.py +121 -0
- anyscale/sdk/anyscale_client/models/node_type.py +100 -0
- anyscale/sdk/anyscale_client/models/object_storage_config.py +122 -0
- anyscale/sdk/anyscale_client/models/object_storage_config_s3.py +256 -0
- anyscale/sdk/anyscale_client/models/objectstorageconfig_response.py +121 -0
- anyscale/sdk/anyscale_client/models/operation_error.py +123 -0
- anyscale/sdk/anyscale_client/models/operation_progress.py +123 -0
- anyscale/sdk/anyscale_client/models/operation_result.py +150 -0
- anyscale/sdk/anyscale_client/models/organization.py +209 -0
- anyscale/sdk/anyscale_client/models/organization_response.py +121 -0
- anyscale/sdk/anyscale_client/models/page_query.py +153 -0
- anyscale/sdk/anyscale_client/models/pause_schedule.py +123 -0
- anyscale/sdk/anyscale_client/models/production_job.py +437 -0
- anyscale/sdk/anyscale_client/models/production_job_config.py +348 -0
- anyscale/sdk/anyscale_client/models/production_job_state_transition.py +293 -0
- anyscale/sdk/anyscale_client/models/production_service_v2_model.py +612 -0
- anyscale/sdk/anyscale_client/models/production_service_v2_version_model.py +437 -0
- anyscale/sdk/anyscale_client/models/productionjob_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/productionjob_response.py +121 -0
- anyscale/sdk/anyscale_client/models/productionservicev2_model_response.py +121 -0
- anyscale/sdk/anyscale_client/models/project.py +467 -0
- anyscale/sdk/anyscale_client/models/project_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/project_response.py +121 -0
- anyscale/sdk/anyscale_client/models/projects_query.py +234 -0
- anyscale/sdk/anyscale_client/models/protocols.py +150 -0
- anyscale/sdk/anyscale_client/models/python_modules.py +150 -0
- anyscale/sdk/anyscale_client/models/python_version.py +105 -0
- anyscale/sdk/anyscale_client/models/ray_gcs_external_storage_config.py +178 -0
- anyscale/sdk/anyscale_client/models/ray_runtime_env_config.py +262 -0
- anyscale/sdk/anyscale_client/models/resources.py +234 -0
- anyscale/sdk/anyscale_client/models/rollback_service_model.py +122 -0
- anyscale/sdk/anyscale_client/models/rollout_strategy.py +100 -0
- anyscale/sdk/anyscale_client/models/runtime_environment.py +406 -0
- anyscale/sdk/anyscale_client/models/runtimeenvironment_response.py +121 -0
- anyscale/sdk/anyscale_client/models/schedule_api_model.py +467 -0
- anyscale/sdk/anyscale_client/models/schedule_config.py +151 -0
- anyscale/sdk/anyscale_client/models/scheduleapimodel_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/scheduleapimodel_response.py +121 -0
- anyscale/sdk/anyscale_client/models/service_config.py +178 -0
- anyscale/sdk/anyscale_client/models/service_event_current_state.py +108 -0
- anyscale/sdk/anyscale_client/models/service_goal_states.py +100 -0
- anyscale/sdk/anyscale_client/models/service_model.py +612 -0
- anyscale/sdk/anyscale_client/models/service_observability_urls.py +206 -0
- anyscale/sdk/anyscale_client/models/service_sort_field.py +101 -0
- anyscale/sdk/anyscale_client/models/service_type.py +100 -0
- anyscale/sdk/anyscale_client/models/service_version_state.py +106 -0
- anyscale/sdk/anyscale_client/models/servicemodel_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/servicemodel_response.py +121 -0
- anyscale/sdk/anyscale_client/models/session.py +1535 -0
- anyscale/sdk/anyscale_client/models/session_command.py +350 -0
- anyscale/sdk/anyscale_client/models/session_command_types.py +100 -0
- anyscale/sdk/anyscale_client/models/session_event.py +267 -0
- anyscale/sdk/anyscale_client/models/session_event_cause.py +150 -0
- anyscale/sdk/anyscale_client/models/session_event_types.py +111 -0
- anyscale/sdk/anyscale_client/models/session_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/session_operation.py +266 -0
- anyscale/sdk/anyscale_client/models/session_operation_type.py +101 -0
- anyscale/sdk/anyscale_client/models/session_response.py +121 -0
- anyscale/sdk/anyscale_client/models/session_starting_up_data.py +146 -0
- anyscale/sdk/anyscale_client/models/session_state.py +111 -0
- anyscale/sdk/anyscale_client/models/session_state_data.py +146 -0
- anyscale/sdk/anyscale_client/models/session_stopping_data.py +146 -0
- anyscale/sdk/anyscale_client/models/sessioncommand_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/sessioncommand_response.py +121 -0
- anyscale/sdk/anyscale_client/models/sessionevent_list_response.py +147 -0
- anyscale/sdk/anyscale_client/models/sessionoperation_response.py +121 -0
- anyscale/sdk/anyscale_client/models/sessions_query.py +206 -0
- anyscale/sdk/anyscale_client/models/sort_by_clause_jobs_sort_field.py +148 -0
- anyscale/sdk/anyscale_client/models/sort_order.py +100 -0
- anyscale/sdk/anyscale_client/models/sso_config.py +237 -0
- anyscale/sdk/anyscale_client/models/sso_mode.py +101 -0
- anyscale/sdk/anyscale_client/models/ssoconfig_response.py +121 -0
- anyscale/sdk/anyscale_client/models/start_cluster_options.py +178 -0
- anyscale/sdk/anyscale_client/models/start_session_options.py +206 -0
- anyscale/sdk/anyscale_client/models/static_sso_config.py +210 -0
- anyscale/sdk/anyscale_client/models/supportedbaseimagesenum.py +1570 -0
- anyscale/sdk/anyscale_client/models/terminate_cluster_options.py +122 -0
- anyscale/sdk/anyscale_client/models/terminate_session_options.py +206 -0
- anyscale/sdk/anyscale_client/models/text_query.py +178 -0
- anyscale/sdk/anyscale_client/models/tracing_config.py +178 -0
- anyscale/sdk/anyscale_client/models/update_app_config.py +122 -0
- anyscale/sdk/anyscale_client/models/update_cloud.py +150 -0
- anyscale/sdk/anyscale_client/models/update_cluster.py +206 -0
- anyscale/sdk/anyscale_client/models/update_compute_template.py +146 -0
- anyscale/sdk/anyscale_client/models/update_compute_template_config.py +464 -0
- anyscale/sdk/anyscale_client/models/update_organization.py +123 -0
- anyscale/sdk/anyscale_client/models/update_project.py +150 -0
- anyscale/sdk/anyscale_client/models/update_session.py +150 -0
- anyscale/sdk/anyscale_client/models/user_service_access_types.py +100 -0
- anyscale/sdk/anyscale_client/models/ux_instance.py +468 -0
- anyscale/sdk/anyscale_client/models/validation_error.py +175 -0
- anyscale/sdk/anyscale_client/models/worker_node_type.py +404 -0
- anyscale/sdk/anyscale_client/rest.py +296 -0
- anyscale/sdk/anyscale_client/sdk.py +634 -0
- anyscale/service/__init__.py +168 -0
- anyscale/service/_private/service_sdk.py +702 -0
- anyscale/service/commands.py +261 -0
- anyscale/service/models.py +671 -0
- anyscale/shared_anyscale_utils/__init__.py +1 -0
- anyscale/shared_anyscale_utils/aws.py +153 -0
- anyscale/shared_anyscale_utils/bytes_util.py +10 -0
- anyscale/shared_anyscale_utils/conf.py +47 -0
- anyscale/shared_anyscale_utils/default_anyscale_aws.yaml +74 -0
- anyscale/shared_anyscale_utils/default_anyscale_gcp.yaml +80 -0
- anyscale/shared_anyscale_utils/headers.py +38 -0
- anyscale/shared_anyscale_utils/latest_ray_version.py +2 -0
- anyscale/shared_anyscale_utils/project.py +15 -0
- anyscale/shared_anyscale_utils/test_util.py +22 -0
- anyscale/shared_anyscale_utils/tests/__init__.py +1 -0
- anyscale/shared_anyscale_utils/tests/test_asyncio.py +41 -0
- anyscale/shared_anyscale_utils/tests/test_ray_semver.py +63 -0
- anyscale/shared_anyscale_utils/util.py +50 -0
- anyscale/shared_anyscale_utils/utils/__init__.py +2 -0
- anyscale/shared_anyscale_utils/utils/asyncio.py +120 -0
- anyscale/shared_anyscale_utils/utils/byod.py +40 -0
- anyscale/shared_anyscale_utils/utils/collections.py +33 -0
- anyscale/shared_anyscale_utils/utils/id_gen.py +147 -0
- anyscale/shared_anyscale_utils/utils/protected_string.py +89 -0
- anyscale/shared_anyscale_utils/utils/ray_semver.py +81 -0
- anyscale/snapshot.py +46 -0
- anyscale/tables.py +82 -0
- anyscale/util.py +1155 -0
- anyscale/utils/__init__.py +0 -0
- anyscale/utils/cli_version_check_util.py +63 -0
- anyscale/utils/cloud_update_utils.py +862 -0
- anyscale/utils/cloud_utils.py +317 -0
- anyscale/utils/cluster_debug.py +191 -0
- anyscale/utils/connect_helpers.py +155 -0
- anyscale/utils/deprecation_util.py +32 -0
- anyscale/utils/entity_arg_utils.py +43 -0
- anyscale/utils/env_utils.py +17 -0
- anyscale/utils/gcp_managed_setup_utils.py +888 -0
- anyscale/utils/gcp_utils.py +312 -0
- anyscale/utils/imports/__init__.py +0 -0
- anyscale/utils/imports/all.py +13 -0
- anyscale/utils/imports/azure.py +14 -0
- anyscale/utils/imports/gcp.py +59 -0
- anyscale/utils/logs_utils.py +141 -0
- anyscale/utils/name_utils.py +33 -0
- anyscale/utils/network_verification.py +153 -0
- anyscale/utils/ray_utils.py +128 -0
- anyscale/utils/ray_version_checker.py +48 -0
- anyscale/utils/ray_version_utils.py +53 -0
- anyscale/utils/runtime_env.py +487 -0
- anyscale/utils/s3.py +92 -0
- anyscale/utils/user_utils.py +17 -0
- anyscale/utils/workload_types.py +7 -0
- anyscale/utils/workspace_notification.py +39 -0
- anyscale/utils/workspace_utils.py +65 -0
- anyscale/version.py +1 -0
- anyscale/webterminal/__init__.py +0 -0
- anyscale/webterminal/bash-preexec.sh +370 -0
- anyscale/webterminal/command_persister.py +164 -0
- anyscale/webterminal/utils.py +176 -0
- anyscale/webterminal/webterminal.py +311 -0
- anyscale/workspace/__init__.py +270 -0
- anyscale/workspace/_private/workspace_sdk.py +737 -0
- anyscale/workspace/commands.py +472 -0
- anyscale/workspace/models.py +296 -0
- anyscale/workspace_utils.py +35 -0
- anyscale-0.24.86.dist-info/LICENSE +68 -0
- anyscale-0.24.86.dist-info/METADATA +82 -0
- anyscale-0.24.86.dist-info/NOTICE +6 -0
- anyscale-0.24.86.dist-info/RECORD +1131 -0
- anyscale-0.24.86.dist-info/WHEEL +5 -0
- anyscale-0.24.86.dist-info/entry_points.txt +2 -0
- anyscale-0.24.86.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,792 @@
|
|
|
1
|
+
import ipaddress
|
|
2
|
+
import re
|
|
3
|
+
from typing import Iterable, List, Optional, Tuple
|
|
4
|
+
|
|
5
|
+
import click
|
|
6
|
+
from click import ClickException
|
|
7
|
+
from google.api_core.exceptions import NotFound, PermissionDenied
|
|
8
|
+
from google.cloud import compute_v1
|
|
9
|
+
from google.cloud.storage.bucket import Bucket
|
|
10
|
+
from google.cloud.storage.constants import (
|
|
11
|
+
PUBLIC_ACCESS_PREVENTION_ENFORCED,
|
|
12
|
+
PUBLIC_ACCESS_PREVENTION_INHERITED,
|
|
13
|
+
)
|
|
14
|
+
from google.iam.v1.policy_pb2 import Binding
|
|
15
|
+
from googleapiclient.errors import HttpError
|
|
16
|
+
|
|
17
|
+
from anyscale.cli_logger import CloudSetupLogger
|
|
18
|
+
from anyscale.client.openapi_client.models import (
|
|
19
|
+
CloudAnalyticsEventCloudResource,
|
|
20
|
+
CreateCloudResourceGCP,
|
|
21
|
+
)
|
|
22
|
+
from anyscale.shared_anyscale_utils.conf import ANYSCALE_CORS_ORIGIN
|
|
23
|
+
from anyscale.utils.cloud_utils import CloudSetupError
|
|
24
|
+
from anyscale.utils.gcp_managed_setup_utils import enable_project_apis
|
|
25
|
+
from anyscale.utils.gcp_utils import (
|
|
26
|
+
binding_from_dictionary,
|
|
27
|
+
check_policy_bindings,
|
|
28
|
+
check_required_policy_bindings,
|
|
29
|
+
GCP_REQUIRED_APIS,
|
|
30
|
+
GCPLogger,
|
|
31
|
+
GoogleCloudClientFactory,
|
|
32
|
+
)
|
|
33
|
+
from anyscale.utils.network_verification import (
|
|
34
|
+
check_inbound_firewall_permissions,
|
|
35
|
+
FirewallRule,
|
|
36
|
+
GCP_SUBNET_CAPACITY,
|
|
37
|
+
Protocol,
|
|
38
|
+
)
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
# Refer to https://cloud.google.com/python/docs/reference/file/latest/google.cloud.filestore_v1.
|
|
42
|
+
# services.cloud_filestore_manager.CloudFilestoreManagerClient, filestore name is in the format
|
|
43
|
+
# projects/{project_id}/locations/{location}/instances/{instance_id}.
|
|
44
|
+
_FILESTORE_NAME_REGEX_PATTERN = r"projects/(?P<project_id>[^/]+)/locations/(?P<location>[^/]+)/instances/(?P<instance_id>[^/]+)"
|
|
45
|
+
|
|
46
|
+
# A subnet with this purpose must be in the VPC for private load balancers to work.
|
|
47
|
+
# See: https://cloud.google.com/load-balancing/docs/proxy-only-subnets
|
|
48
|
+
PROXY_ONLY_SUBNET_PURPOSE = "REGIONAL_MANAGED_PROXY"
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
def verify_gcp_networking(
|
|
52
|
+
factory: GoogleCloudClientFactory,
|
|
53
|
+
resources: CreateCloudResourceGCP,
|
|
54
|
+
project_id: str,
|
|
55
|
+
cloud_region: str,
|
|
56
|
+
logger: GCPLogger,
|
|
57
|
+
strict: bool = False,
|
|
58
|
+
is_private_service_cloud: bool = False,
|
|
59
|
+
) -> bool:
|
|
60
|
+
"""Verify the existence and connectedness of the VPC & Subnet."""
|
|
61
|
+
vpc_name = resources.gcp_vpc_id
|
|
62
|
+
# TODO Verify Internet Gateway
|
|
63
|
+
try:
|
|
64
|
+
vpc = factory.compute_v1.NetworksClient().get(
|
|
65
|
+
project=project_id, network=vpc_name
|
|
66
|
+
)
|
|
67
|
+
except NotFound:
|
|
68
|
+
logger.log_resource_not_found_error("VPC", vpc_name, project_id)
|
|
69
|
+
return False
|
|
70
|
+
|
|
71
|
+
subnet_name = resources.gcp_subnet_ids[
|
|
72
|
+
0
|
|
73
|
+
] # TODO (congding): multiple subnets provided
|
|
74
|
+
if len(resources.gcp_subnet_ids) > 1:
|
|
75
|
+
logger.internal.warning(
|
|
76
|
+
"Multiple subnets provided. Only taking the first subnet and ignoring the rest."
|
|
77
|
+
)
|
|
78
|
+
if strict:
|
|
79
|
+
return False
|
|
80
|
+
try:
|
|
81
|
+
subnet = factory.compute_v1.SubnetworksClient().get(
|
|
82
|
+
project=project_id, subnetwork=subnet_name, region=cloud_region,
|
|
83
|
+
)
|
|
84
|
+
except NotFound:
|
|
85
|
+
logger.log_resource_not_found_error("Subnet", subnet_name, project_id)
|
|
86
|
+
return False
|
|
87
|
+
|
|
88
|
+
if subnet.network != vpc.self_link:
|
|
89
|
+
logger.internal.log_resource_error(
|
|
90
|
+
CloudAnalyticsEventCloudResource.GCP_SUBNET,
|
|
91
|
+
CloudSetupError.SUBNET_NOT_IN_VPC,
|
|
92
|
+
)
|
|
93
|
+
logger.internal.error(f"Subnet {subnet_name} is not part of {vpc_name}!")
|
|
94
|
+
return False
|
|
95
|
+
|
|
96
|
+
if is_private_service_cloud and not _get_proxy_only_subnet_in_vpc(
|
|
97
|
+
factory, project_id, cloud_region, vpc_name
|
|
98
|
+
):
|
|
99
|
+
logger.internal.warning(
|
|
100
|
+
f"Could not find a subnet with purpose `{PROXY_ONLY_SUBNET_PURPOSE}` in the VPC {vpc_name}. A proxy-only subnet is required to run private Anyscale Services in your account. See https://cloud.google.com/load-balancing/docs/proxy-only-subnets for more details."
|
|
101
|
+
)
|
|
102
|
+
if strict:
|
|
103
|
+
return False
|
|
104
|
+
|
|
105
|
+
return _gcp_subnet_has_enough_capacity(subnet, logger.internal)
|
|
106
|
+
|
|
107
|
+
|
|
108
|
+
def _gcp_subnet_has_enough_capacity(
|
|
109
|
+
subnet: compute_v1.types.compute.Subnetwork, logger: CloudSetupLogger
|
|
110
|
+
) -> bool:
|
|
111
|
+
"""Verify if the subnet provided has a large enough IP address block."""
|
|
112
|
+
if GCP_SUBNET_CAPACITY.verify_network_capacity(
|
|
113
|
+
cidr_block_str=subnet.ip_cidr_range, resource_name=subnet.name, logger=logger,
|
|
114
|
+
):
|
|
115
|
+
return True
|
|
116
|
+
return False
|
|
117
|
+
|
|
118
|
+
|
|
119
|
+
def _get_proxy_only_subnet_in_vpc(
|
|
120
|
+
factory: GoogleCloudClientFactory,
|
|
121
|
+
project_id: str,
|
|
122
|
+
cloud_region: str,
|
|
123
|
+
vpc_name: str,
|
|
124
|
+
) -> Optional[compute_v1.types.compute.Subnetwork]:
|
|
125
|
+
# Check if there exists a subnet in the VPC and region with purpose `REGIONAL_MANAGED_PROXY`
|
|
126
|
+
subnets = factory.compute_v1.SubnetworksClient().list(
|
|
127
|
+
project=project_id, region=cloud_region
|
|
128
|
+
)
|
|
129
|
+
for subnet in subnets:
|
|
130
|
+
subnet_vpc = subnet.network.split("/")[-1]
|
|
131
|
+
if vpc_name == subnet_vpc and subnet.purpose == PROXY_ONLY_SUBNET_PURPOSE:
|
|
132
|
+
return subnet
|
|
133
|
+
return None
|
|
134
|
+
|
|
135
|
+
|
|
136
|
+
def verify_gcp_project( # noqa: PLR0911
|
|
137
|
+
factory: GoogleCloudClientFactory,
|
|
138
|
+
resources: CreateCloudResourceGCP,
|
|
139
|
+
project_id: str,
|
|
140
|
+
logger: GCPLogger,
|
|
141
|
+
strict: bool = False,
|
|
142
|
+
) -> bool:
|
|
143
|
+
"""Verify if the project exists and is active.
|
|
144
|
+
|
|
145
|
+
NOTE: This also checks that Compute Engine Service Agent is configured in the default way.
|
|
146
|
+
"""
|
|
147
|
+
project_client = factory.resourcemanager_v3.ProjectsClient()
|
|
148
|
+
try:
|
|
149
|
+
project = project_client.get_project(name=f"projects/{project_id}")
|
|
150
|
+
except (NotFound, PermissionDenied):
|
|
151
|
+
logger.log_resource_not_found_error("Project", project_id)
|
|
152
|
+
return False
|
|
153
|
+
if project.state != project.State.ACTIVE:
|
|
154
|
+
logger.internal.log_resource_error(
|
|
155
|
+
CloudAnalyticsEventCloudResource.GCP_PROJECT,
|
|
156
|
+
CloudSetupError.PROJECT_NOT_ACTIVE,
|
|
157
|
+
)
|
|
158
|
+
logger.internal.error(
|
|
159
|
+
f"Project {project_id} is in state: {project.state}, not active"
|
|
160
|
+
)
|
|
161
|
+
return False
|
|
162
|
+
|
|
163
|
+
iam_policies = project_client.get_iam_policy(resource=f"projects/{project_id}")
|
|
164
|
+
project_number = project.name.split("/")[1]
|
|
165
|
+
|
|
166
|
+
if not check_policy_bindings(
|
|
167
|
+
iam_policies.bindings,
|
|
168
|
+
f"serviceAccount:service-{project_number}@compute-system.iam.gserviceaccount.com",
|
|
169
|
+
{"roles/compute.serviceAgent"},
|
|
170
|
+
):
|
|
171
|
+
logger.internal.warning(
|
|
172
|
+
"The Compute Engine Service Agent does not have the standard IAM Role of 'roles/compute.serviceAgent' in your project.\n"
|
|
173
|
+
"This is not recommended by Google and may result in an inability for Compute Engine to function properly:\n"
|
|
174
|
+
"https://cloud.google.com/compute/docs/access/service-accounts#compute_engine_service_account"
|
|
175
|
+
)
|
|
176
|
+
if strict:
|
|
177
|
+
return False
|
|
178
|
+
|
|
179
|
+
# Verify that APIs are Enabled
|
|
180
|
+
service_usage_client = factory.build("serviceusage", "v1")
|
|
181
|
+
enable_memorystore_api = resources.memorystore_instance_config is not None
|
|
182
|
+
if enable_memorystore_api:
|
|
183
|
+
apis = GCP_REQUIRED_APIS + ["redis.googleapis.com"] # Memorystore for Redis
|
|
184
|
+
else:
|
|
185
|
+
apis = GCP_REQUIRED_APIS
|
|
186
|
+
response = (
|
|
187
|
+
service_usage_client.services()
|
|
188
|
+
.batchGet(
|
|
189
|
+
parent=f"projects/{project_id}",
|
|
190
|
+
names=[f"projects/{project_id}/services/{api}" for api in apis],
|
|
191
|
+
)
|
|
192
|
+
.execute()
|
|
193
|
+
)
|
|
194
|
+
|
|
195
|
+
unenabled_apis = [
|
|
196
|
+
service["config"]["name"]
|
|
197
|
+
for service in response["services"]
|
|
198
|
+
if service["state"] != "ENABLED"
|
|
199
|
+
]
|
|
200
|
+
if len(unenabled_apis) == 0:
|
|
201
|
+
return True
|
|
202
|
+
logger.spinner.stop()
|
|
203
|
+
if not logger.yes and not click.confirm(
|
|
204
|
+
f"The following APIs are not enabled in your project: {unenabled_apis}\n"
|
|
205
|
+
"Anyscale won't function properly if you don't enable these APIs.\n"
|
|
206
|
+
"Would you like to enable these APIs and proceed?"
|
|
207
|
+
):
|
|
208
|
+
logger.spinner.start()
|
|
209
|
+
logger.internal.log_resource_error(
|
|
210
|
+
CloudAnalyticsEventCloudResource.GCP_PROJECT,
|
|
211
|
+
CloudSetupError.API_NOT_ENABLED,
|
|
212
|
+
)
|
|
213
|
+
return False
|
|
214
|
+
|
|
215
|
+
spinner_text = logger.spinner.text
|
|
216
|
+
logger.spinner.text = "Enabling APIs..."
|
|
217
|
+
logger.spinner.start()
|
|
218
|
+
|
|
219
|
+
# enable all required apis, the operation is idompotent
|
|
220
|
+
try:
|
|
221
|
+
enable_project_apis(
|
|
222
|
+
factory, project_id, logger.internal, enable_memorystore_api
|
|
223
|
+
)
|
|
224
|
+
except ClickException as e:
|
|
225
|
+
logger.internal.error(e.message)
|
|
226
|
+
logger.spinner.text = spinner_text
|
|
227
|
+
return False
|
|
228
|
+
|
|
229
|
+
# APIs are enabled successfully
|
|
230
|
+
logger.spinner.text = spinner_text
|
|
231
|
+
return True
|
|
232
|
+
|
|
233
|
+
|
|
234
|
+
def verify_gcp_access_service_account(
|
|
235
|
+
factory: GoogleCloudClientFactory,
|
|
236
|
+
resources: CreateCloudResourceGCP,
|
|
237
|
+
project_id: str,
|
|
238
|
+
logger: GCPLogger,
|
|
239
|
+
) -> bool:
|
|
240
|
+
"""Verify if the Service Account meant to grant Anyscale access to this cloud has access to the specified project.
|
|
241
|
+
|
|
242
|
+
NOTE: We verify that this service account can call signBlob on itself because this is necessary for downloading logs.
|
|
243
|
+
"""
|
|
244
|
+
anyscale_access_service_account = resources.gcp_anyscale_iam_service_account_email
|
|
245
|
+
|
|
246
|
+
service_account_client = factory.build("iam", "v1").projects().serviceAccounts()
|
|
247
|
+
try:
|
|
248
|
+
service_account_iam_policy = service_account_client.getIamPolicy(
|
|
249
|
+
resource=f"projects/-/serviceAccounts/{anyscale_access_service_account}"
|
|
250
|
+
).execute()
|
|
251
|
+
except HttpError as e:
|
|
252
|
+
if e.status_code == 404:
|
|
253
|
+
logger.log_resource_not_found_error(
|
|
254
|
+
"Anyscale Access Service Account", anyscale_access_service_account
|
|
255
|
+
)
|
|
256
|
+
else:
|
|
257
|
+
logger.internal.log_resource_exception(
|
|
258
|
+
CloudAnalyticsEventCloudResource.GCP_SERVICE_ACCOUNT, e
|
|
259
|
+
)
|
|
260
|
+
logger.internal.error(str(e))
|
|
261
|
+
return False
|
|
262
|
+
|
|
263
|
+
if service_account_iam_policy.get("bindings") is None or not check_policy_bindings(
|
|
264
|
+
binding_from_dictionary(service_account_iam_policy["bindings"]),
|
|
265
|
+
f"serviceAccount:{anyscale_access_service_account}",
|
|
266
|
+
{"roles/iam.serviceAccountTokenCreator"},
|
|
267
|
+
):
|
|
268
|
+
logger.confirm_missing_permission(
|
|
269
|
+
f"Service Account {anyscale_access_service_account} must have the `iam.serviceAccounts.signBlob` permission to perform log download from the Anyscale platform.\n"
|
|
270
|
+
"Please grant the `roles/iam.serviceAccountTokenCreator` role to this Service Account to pass this check."
|
|
271
|
+
)
|
|
272
|
+
|
|
273
|
+
project_client = factory.resourcemanager_v3.ProjectsClient()
|
|
274
|
+
iam_policies = project_client.get_iam_policy(resource=f"projects/{project_id}")
|
|
275
|
+
if not check_policy_bindings(
|
|
276
|
+
iam_policies.bindings,
|
|
277
|
+
f"serviceAccount:{anyscale_access_service_account}",
|
|
278
|
+
{"roles/editor", "roles/owner"},
|
|
279
|
+
):
|
|
280
|
+
logger.confirm_missing_permission(
|
|
281
|
+
f"Service Account {anyscale_access_service_account} must have either `roles/editor` or `roles/owner` roles on the Project {project_id}.\n"
|
|
282
|
+
"A more fine-grained set of permissions may be possible, but may break Anyscale's functionality."
|
|
283
|
+
)
|
|
284
|
+
|
|
285
|
+
return True
|
|
286
|
+
|
|
287
|
+
|
|
288
|
+
def verify_gcp_dataplane_service_account(
|
|
289
|
+
factory: GoogleCloudClientFactory,
|
|
290
|
+
resources: CreateCloudResourceGCP,
|
|
291
|
+
project_id: str,
|
|
292
|
+
logger: GCPLogger,
|
|
293
|
+
strict: bool = False,
|
|
294
|
+
) -> bool:
|
|
295
|
+
"""Verify that the Service Account for compute instances exists *in* the specified project.
|
|
296
|
+
|
|
297
|
+
Compute Engine's ability to use this role
|
|
298
|
+
This relies on the fact that Compute Engine Service Agent has the roles/compute.serviceAgent Role
|
|
299
|
+
"""
|
|
300
|
+
service_account = resources.gcp_cluster_node_service_account_email
|
|
301
|
+
service_account_client = factory.build("iam", "v1").projects().serviceAccounts()
|
|
302
|
+
try:
|
|
303
|
+
resp = service_account_client.get(
|
|
304
|
+
name=f"projects/-/serviceAccounts/{service_account}"
|
|
305
|
+
).execute()
|
|
306
|
+
except HttpError as e:
|
|
307
|
+
if e.status_code == 404:
|
|
308
|
+
logger.log_resource_not_found_error(
|
|
309
|
+
"Dataplane Service Account", service_account
|
|
310
|
+
)
|
|
311
|
+
else:
|
|
312
|
+
logger.internal.log_resource_exception(
|
|
313
|
+
CloudAnalyticsEventCloudResource.GCP_SERVICE_ACCOUNT, e
|
|
314
|
+
)
|
|
315
|
+
logger.internal.error(str(e))
|
|
316
|
+
return False
|
|
317
|
+
|
|
318
|
+
if resp["projectId"] != project_id:
|
|
319
|
+
logger.internal.warning(
|
|
320
|
+
"Service Account {} is in project {}, not {}. Please ensure that `constraints/iam.disableCrossProjectServiceAccountUsage` is not enforced.\n"
|
|
321
|
+
"See: https://cloud.google.com/iam/docs/attach-service-accounts#enabling-cross-project for more information.".format(
|
|
322
|
+
service_account, resp["projectId"], project_id
|
|
323
|
+
)
|
|
324
|
+
)
|
|
325
|
+
if strict:
|
|
326
|
+
return False
|
|
327
|
+
|
|
328
|
+
project_client = factory.resourcemanager_v3.ProjectsClient()
|
|
329
|
+
project_iam_bindings = project_client.get_iam_policy(
|
|
330
|
+
resource=f"projects/{project_id}"
|
|
331
|
+
)
|
|
332
|
+
if not check_policy_bindings(
|
|
333
|
+
project_iam_bindings.bindings,
|
|
334
|
+
f"serviceAccount:{service_account}",
|
|
335
|
+
{"roles/artifactregistry.reader", "roles/viewer"},
|
|
336
|
+
):
|
|
337
|
+
logger.internal.warning(
|
|
338
|
+
f"The dataplane Service Account {service_account} does not have `roles/artifactregistry.reader` or `roles/viewer` on {project_id}.\n"
|
|
339
|
+
"This is safe to ignore if you are not using your own container images or are configuring access a different way."
|
|
340
|
+
)
|
|
341
|
+
if strict:
|
|
342
|
+
return False
|
|
343
|
+
|
|
344
|
+
return True
|
|
345
|
+
|
|
346
|
+
|
|
347
|
+
def verify_firewall_policy( # noqa: PLR0911, PLR0912, C901, PLR0913
|
|
348
|
+
factory: GoogleCloudClientFactory,
|
|
349
|
+
resources: CreateCloudResourceGCP,
|
|
350
|
+
project_id: str,
|
|
351
|
+
cloud_region: str,
|
|
352
|
+
use_shared_vpc: bool,
|
|
353
|
+
is_private_service_cloud: bool,
|
|
354
|
+
logger: GCPLogger,
|
|
355
|
+
strict: bool = False,
|
|
356
|
+
) -> bool:
|
|
357
|
+
"""Checks if the given firewall exists at either the Global or Regional level."""
|
|
358
|
+
firewall_policy = resources.gcp_firewall_policy_ids[
|
|
359
|
+
0
|
|
360
|
+
] # TODO (congding): multiple firewall ids provided
|
|
361
|
+
if len(resources.gcp_firewall_policy_ids) > 1:
|
|
362
|
+
logger.internal.warning(
|
|
363
|
+
"Multiple firewall policies provided. Only taking the first firewall policy and ignoring the rest."
|
|
364
|
+
)
|
|
365
|
+
if strict:
|
|
366
|
+
return False
|
|
367
|
+
vpc_name = resources.gcp_vpc_id
|
|
368
|
+
|
|
369
|
+
firewall = compute_v1.types.compute.FirewallPolicy()
|
|
370
|
+
try:
|
|
371
|
+
firewall = factory.compute_v1.NetworkFirewallPoliciesClient().get(
|
|
372
|
+
project=project_id, firewall_policy=firewall_policy
|
|
373
|
+
)
|
|
374
|
+
except NotFound:
|
|
375
|
+
logger.internal.info(
|
|
376
|
+
f"Global firweall policy {firewall_policy} not found, trying in region: {cloud_region}."
|
|
377
|
+
)
|
|
378
|
+
if not firewall:
|
|
379
|
+
try:
|
|
380
|
+
firewall = factory.compute_v1.RegionNetworkFirewallPoliciesClient().get(
|
|
381
|
+
project=project_id, firewall_policy=firewall_policy, region=cloud_region
|
|
382
|
+
)
|
|
383
|
+
except NotFound:
|
|
384
|
+
logger.log_resource_not_found_error(
|
|
385
|
+
"Firewall Policy", firewall_policy, project_id
|
|
386
|
+
)
|
|
387
|
+
return False
|
|
388
|
+
|
|
389
|
+
if not any(
|
|
390
|
+
association.attachment_target.split("/")[-1] == vpc_name
|
|
391
|
+
for association in firewall.associations
|
|
392
|
+
):
|
|
393
|
+
logger.internal.log_resource_error(
|
|
394
|
+
CloudAnalyticsEventCloudResource.GCP_FIREWALL_POLICY,
|
|
395
|
+
CloudSetupError.FIREWALL_NOT_ASSOCIATED_WITH_VPC,
|
|
396
|
+
)
|
|
397
|
+
logger.internal.error(
|
|
398
|
+
"Firewall policy {} is not associated with the VPC {}, but is associated with the following VPCs: {}".format(
|
|
399
|
+
firewall_policy, vpc_name, firewall.associations
|
|
400
|
+
)
|
|
401
|
+
)
|
|
402
|
+
return False
|
|
403
|
+
|
|
404
|
+
subnet_obj = factory.compute_v1.SubnetworksClient().get(
|
|
405
|
+
project=project_id, subnetwork=resources.gcp_subnet_ids[0], region=cloud_region
|
|
406
|
+
) # TODO (congding): multiple subnets provided
|
|
407
|
+
subnet = ipaddress.ip_network(subnet_obj.ip_cidr_range)
|
|
408
|
+
|
|
409
|
+
rules = _firewall_rules_from_proto_resp(firewall.rules)
|
|
410
|
+
if not check_inbound_firewall_permissions(
|
|
411
|
+
rules,
|
|
412
|
+
Protocol.tcp,
|
|
413
|
+
{22},
|
|
414
|
+
ipaddress.ip_network("0.0.0.0/0"),
|
|
415
|
+
check_ingress_source_range=False,
|
|
416
|
+
):
|
|
417
|
+
logger.internal.warning(
|
|
418
|
+
"Firewall policy does not allow inbound access on port 22. Certain features may be unavailable."
|
|
419
|
+
)
|
|
420
|
+
if strict:
|
|
421
|
+
return False
|
|
422
|
+
if not check_inbound_firewall_permissions(
|
|
423
|
+
rules,
|
|
424
|
+
Protocol.tcp,
|
|
425
|
+
{443},
|
|
426
|
+
ipaddress.ip_network("0.0.0.0/0"),
|
|
427
|
+
check_ingress_source_range=False,
|
|
428
|
+
):
|
|
429
|
+
logger.internal.warning(
|
|
430
|
+
"Firewall policy does not allow inbound access on port 443. Accessing features like Jupyter & Ray Dashboard may not work."
|
|
431
|
+
)
|
|
432
|
+
if strict:
|
|
433
|
+
return False
|
|
434
|
+
|
|
435
|
+
# If shared VPC is used, we need to check the firewall rule for Anyscale services is added
|
|
436
|
+
# Since our service account cannot update the firewall policy in host project, so we need to make sure the rule is added during cloud setup
|
|
437
|
+
if use_shared_vpc and not (
|
|
438
|
+
check_inbound_firewall_permissions(
|
|
439
|
+
rules, Protocol.tcp, {8000}, ipaddress.ip_network("35.191.0.0/16")
|
|
440
|
+
)
|
|
441
|
+
and check_inbound_firewall_permissions(
|
|
442
|
+
rules, Protocol.tcp, {8000}, ipaddress.ip_network("130.211.0.0/22")
|
|
443
|
+
)
|
|
444
|
+
):
|
|
445
|
+
logger.internal.warning(
|
|
446
|
+
"Firewall policy does not allow inbound access on port 8000 from '35.191.0.0/16' and '130.211.0.0/22'. "
|
|
447
|
+
"This is required for Anyscale services to work correctly. "
|
|
448
|
+
"See https://cloud.google.com/load-balancing/docs/health-checks#fw-rule for more details."
|
|
449
|
+
)
|
|
450
|
+
if strict:
|
|
451
|
+
return False
|
|
452
|
+
|
|
453
|
+
if use_shared_vpc and is_private_service_cloud:
|
|
454
|
+
proxy_only_subnet = _get_proxy_only_subnet_in_vpc(
|
|
455
|
+
factory, project_id, cloud_region, vpc_name
|
|
456
|
+
)
|
|
457
|
+
if not proxy_only_subnet:
|
|
458
|
+
logger.internal.warning(
|
|
459
|
+
f"Could not find a subnet with purpose `{PROXY_ONLY_SUBNET_PURPOSE}` in the VPC {vpc_name}. A proxy-only subnet is required to run private Anyscale Services in your account. See https://cloud.google.com/load-balancing/docs/proxy-only-subnets for more details."
|
|
460
|
+
)
|
|
461
|
+
if strict:
|
|
462
|
+
return False
|
|
463
|
+
elif not check_inbound_firewall_permissions(
|
|
464
|
+
rules,
|
|
465
|
+
Protocol.tcp,
|
|
466
|
+
{8000},
|
|
467
|
+
ipaddress.ip_network(proxy_only_subnet.ip_cidr_range),
|
|
468
|
+
):
|
|
469
|
+
logger.internal.warning(
|
|
470
|
+
"Firewall policy does not allow inbound access from the proxy-only subnet on port 8000. "
|
|
471
|
+
"This is required for private Anyscale services to work correctly. "
|
|
472
|
+
)
|
|
473
|
+
if strict:
|
|
474
|
+
return False
|
|
475
|
+
|
|
476
|
+
if not check_inbound_firewall_permissions(rules, Protocol.tcp, None, subnet):
|
|
477
|
+
logger.internal.error(
|
|
478
|
+
"Firewall policy does not allow for internal communication, see https://cloud.google.com/vpc/docs/using-firewalls#common-use-cases-allow-internal for how to configure such a rule."
|
|
479
|
+
)
|
|
480
|
+
logger.internal.log_resource_error(
|
|
481
|
+
CloudAnalyticsEventCloudResource.GCP_FIREWALL_POLICY,
|
|
482
|
+
CloudSetupError.INTERNAL_COMMUNICATION_NOT_ALLOWED,
|
|
483
|
+
)
|
|
484
|
+
return False
|
|
485
|
+
return True
|
|
486
|
+
|
|
487
|
+
|
|
488
|
+
def _firewall_rules_from_proto_resp(
|
|
489
|
+
rules: Iterable[compute_v1.types.compute.FirewallPolicyRule],
|
|
490
|
+
) -> List[FirewallRule]:
|
|
491
|
+
"""Convert Firewall Rules into a Python class suitable for comparison.
|
|
492
|
+
|
|
493
|
+
NOTE: We only check "ALLOW" rules & do not check priority.
|
|
494
|
+
"""
|
|
495
|
+
return [
|
|
496
|
+
FirewallRule(
|
|
497
|
+
direction=rule.direction,
|
|
498
|
+
protocol=Protocol.from_val(l4config.ip_protocol),
|
|
499
|
+
ports=l4config.ports,
|
|
500
|
+
network=ipaddress.ip_network(addr),
|
|
501
|
+
)
|
|
502
|
+
for rule in rules
|
|
503
|
+
if rule.action == "allow"
|
|
504
|
+
for addr in rule.match.src_ip_ranges
|
|
505
|
+
for l4config in (
|
|
506
|
+
rule.match.layer4_configs
|
|
507
|
+
or [
|
|
508
|
+
compute_v1.types.compute.FirewallPolicyRuleMatcherLayer4Config(
|
|
509
|
+
ip_protocol="all"
|
|
510
|
+
)
|
|
511
|
+
]
|
|
512
|
+
)
|
|
513
|
+
]
|
|
514
|
+
|
|
515
|
+
|
|
516
|
+
def verify_filestore(
|
|
517
|
+
factory: GoogleCloudClientFactory,
|
|
518
|
+
resources: CreateCloudResourceGCP,
|
|
519
|
+
cloud_region: str,
|
|
520
|
+
logger: GCPLogger,
|
|
521
|
+
strict: bool = False,
|
|
522
|
+
) -> bool:
|
|
523
|
+
"""Verify Filestore exists & that it is connected to the correct VPC.
|
|
524
|
+
|
|
525
|
+
TODO: Warn about Filestore size if it is 'too small'."""
|
|
526
|
+
file_store_instance_name = resources.gcp_filestore_config.instance_name
|
|
527
|
+
client = factory.filestore_v1.CloudFilestoreManagerClient()
|
|
528
|
+
try:
|
|
529
|
+
file_store = client.get_instance(name=file_store_instance_name)
|
|
530
|
+
except NotFound:
|
|
531
|
+
logger.log_resource_not_found_error("Filestore", file_store_instance_name)
|
|
532
|
+
return False
|
|
533
|
+
|
|
534
|
+
file_store_match = re.match(_FILESTORE_NAME_REGEX_PATTERN, file_store.name)
|
|
535
|
+
if file_store_match:
|
|
536
|
+
filestore_location = file_store_match.group("location")
|
|
537
|
+
# Filestore location can be region or zone.
|
|
538
|
+
if cloud_region not in filestore_location:
|
|
539
|
+
logger.internal.warning(
|
|
540
|
+
f"Filestore is in {filestore_location}, but this cloud is being set up in {cloud_region}. This can result in cross-region network egress charges, refer to https://cloud.google.com/vpc/network-pricing#egress-within-gcp."
|
|
541
|
+
)
|
|
542
|
+
if strict:
|
|
543
|
+
return False
|
|
544
|
+
else:
|
|
545
|
+
logger.internal.log_resource_error(
|
|
546
|
+
CloudAnalyticsEventCloudResource.GCP_FILESTORE,
|
|
547
|
+
CloudSetupError.FILESTORE_NAME_MALFORMED,
|
|
548
|
+
)
|
|
549
|
+
logger.internal.error(
|
|
550
|
+
f"Failed to get filestore location, since filestore name doesn't match format {_FILESTORE_NAME_REGEX_PATTERN}!"
|
|
551
|
+
)
|
|
552
|
+
return False
|
|
553
|
+
|
|
554
|
+
file_store_networks = [v.network for v in file_store.networks]
|
|
555
|
+
vpc_name = resources.gcp_vpc_id
|
|
556
|
+
if not any(vpc_name == network.split("/")[-1] for network in file_store_networks):
|
|
557
|
+
logger.internal.log_resource_error(
|
|
558
|
+
CloudAnalyticsEventCloudResource.GCP_FILESTORE,
|
|
559
|
+
CloudSetupError.FILESTORE_NOT_CONNECTED_TO_VPC,
|
|
560
|
+
)
|
|
561
|
+
logger.internal.error(
|
|
562
|
+
f"Filestore is not connected to {vpc_name}, but to {file_store_networks}. "
|
|
563
|
+
f"This cannot be edited on an existing Filestore instance. Please recreate the filestore and connect it to {vpc_name}."
|
|
564
|
+
)
|
|
565
|
+
return False
|
|
566
|
+
|
|
567
|
+
return True
|
|
568
|
+
|
|
569
|
+
|
|
570
|
+
def verify_cloud_storage( # noqa: PLR0911, PLR0912
|
|
571
|
+
factory: GoogleCloudClientFactory,
|
|
572
|
+
resources: CreateCloudResourceGCP,
|
|
573
|
+
project_id: str,
|
|
574
|
+
cloud_region: str,
|
|
575
|
+
logger: GCPLogger,
|
|
576
|
+
strict: bool = False,
|
|
577
|
+
):
|
|
578
|
+
"""Verify that the Google Cloud Storage Bucket exists & raises warnings about improper configurations."""
|
|
579
|
+
bucket_client = factory.storage.Client(project_id)
|
|
580
|
+
bucket_name = resources.gcp_cloud_storage_bucket_id
|
|
581
|
+
try:
|
|
582
|
+
bucket = bucket_client.get_bucket(bucket_name)
|
|
583
|
+
except NotFound:
|
|
584
|
+
logger.log_resource_not_found_error("Google Cloud Storage Bucket", bucket_name)
|
|
585
|
+
return False
|
|
586
|
+
|
|
587
|
+
if not bucket.iam_configuration.uniform_bucket_level_access_enabled:
|
|
588
|
+
logger.internal.warning(
|
|
589
|
+
f"Bucket {bucket_name}, does not have Uniform Bucket Access enabled, "
|
|
590
|
+
"this impedes Anyscale's ability to verify bucket access."
|
|
591
|
+
)
|
|
592
|
+
|
|
593
|
+
public_access_protection = bucket.iam_configuration.public_access_prevention
|
|
594
|
+
if public_access_protection not in (
|
|
595
|
+
PUBLIC_ACCESS_PREVENTION_INHERITED,
|
|
596
|
+
PUBLIC_ACCESS_PREVENTION_ENFORCED,
|
|
597
|
+
):
|
|
598
|
+
logger.internal.warning(
|
|
599
|
+
f"Bucket {bucket_name} has public access prevention set to {public_access_protection}, not enforced or inherited."
|
|
600
|
+
)
|
|
601
|
+
if strict:
|
|
602
|
+
return False
|
|
603
|
+
|
|
604
|
+
correct_region, bucket_region = _check_bucket_region(bucket, cloud_region)
|
|
605
|
+
if not correct_region:
|
|
606
|
+
logger.internal.warning(
|
|
607
|
+
f"Bucket {bucket_name} is in region {bucket_region}, but this cloud is being set up in {cloud_region}."
|
|
608
|
+
"This can result in degraded cluster launch & logging performance."
|
|
609
|
+
)
|
|
610
|
+
if strict:
|
|
611
|
+
return False
|
|
612
|
+
|
|
613
|
+
if not any(
|
|
614
|
+
(
|
|
615
|
+
ANYSCALE_CORS_ORIGIN in cors_config.get("origin")
|
|
616
|
+
and "*" in cors_config.get("responseHeader", [])
|
|
617
|
+
and "GET" in cors_config.get("method", [])
|
|
618
|
+
)
|
|
619
|
+
for cors_config in bucket.cors
|
|
620
|
+
):
|
|
621
|
+
logger.internal.warning(
|
|
622
|
+
f"Bucket {bucket_name} does not have the correct CORS rule for Anyscale. This is safe to ignore if you are not using Anyscale UI.\n"
|
|
623
|
+
"If you are using the UI, please create the correct CORS rule for Anyscale according to https://docs.anyscale.com/cloud-deployment/gcp/deploy-cloud?cloud-deployment=custom#4-create-an-anyscale-cloud"
|
|
624
|
+
)
|
|
625
|
+
if strict:
|
|
626
|
+
return False
|
|
627
|
+
|
|
628
|
+
iam_policy = bucket.get_iam_policy()
|
|
629
|
+
iam_bindings = binding_from_dictionary(iam_policy.bindings)
|
|
630
|
+
|
|
631
|
+
permission_warning = (
|
|
632
|
+
"The {location} Service Account {email} requires the following permissions on Bucket {bucket} to operate correctly:\n"
|
|
633
|
+
"* storage.buckets.get\n* storage.objects.[ get | list | create ]\n* storage.multipartUploads.[ abort | create | listParts ]\n"
|
|
634
|
+
"We suggest granting the predefined roles of `roles/storage.legacyBucketReader` and `roles/storage.objectAdmin`."
|
|
635
|
+
)
|
|
636
|
+
|
|
637
|
+
access_service_account = resources.gcp_anyscale_iam_service_account_email
|
|
638
|
+
if not _verify_service_account_on_bucket(
|
|
639
|
+
f"serviceAccount:{access_service_account}", iam_bindings
|
|
640
|
+
):
|
|
641
|
+
logger.confirm_missing_permission(
|
|
642
|
+
permission_warning.format(
|
|
643
|
+
location="Anyscale access",
|
|
644
|
+
email=access_service_account,
|
|
645
|
+
bucket=bucket_name,
|
|
646
|
+
)
|
|
647
|
+
)
|
|
648
|
+
if strict:
|
|
649
|
+
return False
|
|
650
|
+
|
|
651
|
+
dataplane_service_account = resources.gcp_cluster_node_service_account_email
|
|
652
|
+
if not _verify_service_account_on_bucket(
|
|
653
|
+
f"serviceAccount:{dataplane_service_account}", iam_bindings
|
|
654
|
+
):
|
|
655
|
+
logger.confirm_missing_permission(
|
|
656
|
+
permission_warning.format(
|
|
657
|
+
location="Dataplane",
|
|
658
|
+
email=dataplane_service_account,
|
|
659
|
+
bucket=bucket_name,
|
|
660
|
+
)
|
|
661
|
+
)
|
|
662
|
+
if strict:
|
|
663
|
+
return False
|
|
664
|
+
|
|
665
|
+
return True
|
|
666
|
+
|
|
667
|
+
|
|
668
|
+
def _verify_service_account_on_bucket(
|
|
669
|
+
service_account: str, iam_bindings: List[Binding]
|
|
670
|
+
) -> bool:
|
|
671
|
+
"""Verifies that the given service account has roles that ensure the following list of permissions:
|
|
672
|
+
* storage.buckets.get: Get bucket info
|
|
673
|
+
* storage.objects.[ get | list | create ]
|
|
674
|
+
* storage.multipartUploads.[ abort | create | listParts ]
|
|
675
|
+
"""
|
|
676
|
+
if check_policy_bindings(iam_bindings, service_account, {"roles/storage.admin"},):
|
|
677
|
+
return True
|
|
678
|
+
return any(
|
|
679
|
+
check_required_policy_bindings(iam_bindings, service_account, combination)
|
|
680
|
+
for combination in [
|
|
681
|
+
{
|
|
682
|
+
# Best Permissions (legacy for `buckets.get`)
|
|
683
|
+
"roles/storage.legacyBucketReader",
|
|
684
|
+
"roles/storage.objectViewer",
|
|
685
|
+
"roles/storage.objectCreator",
|
|
686
|
+
},
|
|
687
|
+
{
|
|
688
|
+
# Most Brief permissions (legacy for `buckets.get`)
|
|
689
|
+
"roles/storage.objectAdmin",
|
|
690
|
+
"roles/storage.legacyBucketReader",
|
|
691
|
+
},
|
|
692
|
+
{
|
|
693
|
+
# Optimal Legacy Roles
|
|
694
|
+
"roles/storage.legacyBucketWriter",
|
|
695
|
+
"roles/storage.legacyObjectReader",
|
|
696
|
+
},
|
|
697
|
+
{
|
|
698
|
+
# Legacy Roles (extra object permissions)
|
|
699
|
+
"roles/storage.legacyBucketWriter",
|
|
700
|
+
"roles/storage.legacyObjectOwner",
|
|
701
|
+
},
|
|
702
|
+
{
|
|
703
|
+
# Legacy Roles (extra bucket permissions)
|
|
704
|
+
"roles/storage.legacyBucketOwner",
|
|
705
|
+
"roles/storage.legacyObjectReader",
|
|
706
|
+
},
|
|
707
|
+
{
|
|
708
|
+
# Legacy Roles (extra bucket/object permissions)
|
|
709
|
+
"roles/storage.legacyBucketOwner",
|
|
710
|
+
"roles/storage.legacyObjectOwner",
|
|
711
|
+
},
|
|
712
|
+
]
|
|
713
|
+
)
|
|
714
|
+
|
|
715
|
+
|
|
716
|
+
def _check_bucket_region(bucket: Bucket, region: str) -> Tuple[bool, str]:
|
|
717
|
+
if bucket.location_type == "dual-region":
|
|
718
|
+
return region.upper() in bucket.data_locations, ",".join(bucket.data_locations)
|
|
719
|
+
elif bucket.location_type == "region":
|
|
720
|
+
return region.upper() == bucket.location, bucket.location
|
|
721
|
+
|
|
722
|
+
# Bucket is `multi-region`, so check if the location (`EU`, `ASIA`, `US`)
|
|
723
|
+
# is the 'prefix' of the region.
|
|
724
|
+
return region.upper().startswith(bucket.location), bucket.location
|
|
725
|
+
|
|
726
|
+
|
|
727
|
+
def verify_memorystore( # noqa: PLR0911
|
|
728
|
+
factory: GoogleCloudClientFactory,
|
|
729
|
+
resources: CreateCloudResourceGCP,
|
|
730
|
+
logger: GCPLogger,
|
|
731
|
+
strict: bool = False,
|
|
732
|
+
):
|
|
733
|
+
"""Verify that the Google Memorystore exists & raises warnings about improper configurations."""
|
|
734
|
+
client = factory.redis_v1.CloudRedisClient()
|
|
735
|
+
|
|
736
|
+
redis_instance_name = resources.memorystore_instance_config.name
|
|
737
|
+
|
|
738
|
+
try:
|
|
739
|
+
redis_instance = client.get_instance(name=redis_instance_name)
|
|
740
|
+
except (NotFound, PermissionDenied):
|
|
741
|
+
logger.log_resource_not_found_error("Memorystore", redis_instance_name)
|
|
742
|
+
return False
|
|
743
|
+
|
|
744
|
+
# Verify memorystore is in the same VPC as the cloud
|
|
745
|
+
cloud_vpc_name = resources.gcp_vpc_id
|
|
746
|
+
redis_vpc_name = redis_instance.authorized_network.split("/")[-1]
|
|
747
|
+
if cloud_vpc_name != redis_vpc_name:
|
|
748
|
+
logger.internal.log_resource_error(
|
|
749
|
+
CloudAnalyticsEventCloudResource.GCP_MEMORYSTORE,
|
|
750
|
+
CloudSetupError.MEMORYSTORE_NOT_CONNECTED_TO_VPC,
|
|
751
|
+
)
|
|
752
|
+
logger.internal.error(
|
|
753
|
+
f"Memorystore is not connected to {cloud_vpc_name}, but to {redis_vpc_name}. "
|
|
754
|
+
f"This cannot be edited on an existing Memorystore instance. Please recreate the Memorystore and connect it to {cloud_vpc_name}."
|
|
755
|
+
)
|
|
756
|
+
return False
|
|
757
|
+
|
|
758
|
+
# Verify memorystore is the standard tier
|
|
759
|
+
if redis_instance.tier.name != "STANDARD_HA":
|
|
760
|
+
logger.internal.warning(
|
|
761
|
+
"Memorystore is not in the standard tier. This can result in degraded performance and availability. Note that this cannot be changed on an existing Memorystore instance."
|
|
762
|
+
)
|
|
763
|
+
if strict:
|
|
764
|
+
return False
|
|
765
|
+
|
|
766
|
+
# Verify that memorystore instance has the maxmemory-policy set to allkeys-lru
|
|
767
|
+
if redis_instance.redis_configs.get("maxmemory-policy") != "allkeys-lru":
|
|
768
|
+
logger.internal.warning(
|
|
769
|
+
"Memorystore does not have the maxmemory-policy set to allkeys-lru. This can result in degraded performance and availability."
|
|
770
|
+
)
|
|
771
|
+
if strict:
|
|
772
|
+
return False
|
|
773
|
+
|
|
774
|
+
# Verify that the memorystore instance has the read replica mode turned on
|
|
775
|
+
if redis_instance.read_replicas_mode.name != "READ_REPLICAS_ENABLED":
|
|
776
|
+
logger.internal.error(
|
|
777
|
+
"Memorystore does not have the read replica mode turned on. This is required for ray head node HA."
|
|
778
|
+
)
|
|
779
|
+
logger.internal.log_resource_error(
|
|
780
|
+
CloudAnalyticsEventCloudResource.GCP_MEMORYSTORE,
|
|
781
|
+
CloudSetupError.MEMORYSTORE_READ_REPLICAS_DISABLED,
|
|
782
|
+
)
|
|
783
|
+
return False
|
|
784
|
+
|
|
785
|
+
# Verify that the memorystore has tls disabled
|
|
786
|
+
if redis_instance.transit_encryption_mode.name != "DISABLED":
|
|
787
|
+
logger.internal.error(
|
|
788
|
+
"Memorystore has TLS enabled. Please create a new memorystore instance with TLS disabled."
|
|
789
|
+
)
|
|
790
|
+
return False
|
|
791
|
+
|
|
792
|
+
return True
|