in google_cloud_automlops/AutoMLOps.py [0:0]
def launchAll(
project_id: str,
pipeline_params: Dict,
artifact_repo_location: Optional[str] = DEFAULT_RESOURCE_LOCATION,
artifact_repo_name: Optional[str] = None,
artifact_repo_type: Optional[str] = ArtifactRepository.ARTIFACT_REGISTRY.value,
base_image: Optional[str] = DEFAULT_BASE_IMAGE,
build_trigger_location: Optional[str] = DEFAULT_RESOURCE_LOCATION,
build_trigger_name: Optional[str] = None,
custom_training_job_specs: Optional[List[Dict]] = None,
deployment_framework: Optional[str] = Deployer.GITHUB_ACTIONS.value,
naming_prefix: Optional[str] = DEFAULT_NAMING_PREFIX,
orchestration_framework: Optional[str] = Orchestrator.KFP.value,
pipeline_job_location: Optional[str] = DEFAULT_RESOURCE_LOCATION,
pipeline_job_runner_service_account: Optional[str] = None,
pipeline_job_submission_service_location: Optional[str] = DEFAULT_RESOURCE_LOCATION,
pipeline_job_submission_service_name: Optional[str] = None,
pipeline_job_submission_service_type: Optional[str] = PipelineJobSubmitter.CLOUD_FUNCTIONS.value,
precheck: Optional[bool] = True,
project_number: Optional[str] = None,
provision_credentials_key: str = None,
provisioning_framework: Optional[str] = Provisioner.GCLOUD.value,
pubsub_topic_name: Optional[str] = None,
schedule_location: Optional[str] = DEFAULT_RESOURCE_LOCATION,
schedule_name: Optional[str] = None,
schedule_pattern: Optional[str] = DEFAULT_SCHEDULE_PATTERN,
setup_model_monitoring: Optional[bool] = False,
source_repo_branch: Optional[str] = DEFAULT_SOURCE_REPO_BRANCH,
source_repo_name: Optional[str] = None,
source_repo_type: Optional[str] = CodeRepository.GITHUB.value,
storage_bucket_location: Optional[str] = DEFAULT_RESOURCE_LOCATION,
storage_bucket_name: Optional[str] = None,
hide_warnings: Optional[bool] = True,
use_ci: Optional[bool] = False,
vpc_connector: Optional[str] = DEFAULT_VPC_CONNECTOR,
workload_identity_pool: Optional[str] = None,
workload_identity_provider: Optional[str] = None,
workload_identity_service_account: Optional[str] = None):
"""Generates relevant pipeline and component artifacts, then provisions resources, builds,
compiles, and submits the PipelineJob. Check constants file for variable default values.
Args:
project_id: The project ID.
pipeline_params: Dictionary containing runtime pipeline parameters.
artifact_repo_location: Region of the artifact repo (default use with Artifact Registry).
artifact_repo_name: Artifact repo name where components are stored (default use with Artifact Registry).
artifact_repo_type: The type of artifact repository to use (e.g. Artifact Registry, JFrog, etc.)
base_image: The image to use in the component base dockerfile.
build_trigger_location: The location of the build trigger (for cloud build).
build_trigger_name: The name of the build trigger (for cloud build).
custom_training_job_specs: Specifies the specs to run the training job with.
deployment_framework: The CI tool to use (e.g. cloud build, github actions, etc.)
naming_prefix: Unique value used to differentiate pipelines and services across AutoMLOps runs.
orchestration_framework: The orchestration framework to use (e.g. kfp, tfx, etc.)
pipeline_job_location: The location to run the Pipeline Job in.
pipeline_job_runner_service_account: Service Account to run PipelineJobs (specify the full string).
pipeline_job_submission_service_location: The location of the cloud submission service.
pipeline_job_submission_service_name: The name of the cloud submission service.
pipeline_job_submission_service_type: The tool to host for the cloud submission service (e.g. cloud run, cloud functions).
precheck: Boolean used to specify whether to check for provisioned resources before deploying.
project_number: The project number.
provision_credentials_key: Either a path to or the contents of a service account key file in JSON format.
provisioning_framework: The IaC tool to use (e.g. Terraform, Pulumi, etc.)
pubsub_topic_name: The name of the pubsub topic to publish to.
schedule_location: The location of the scheduler resource.
schedule_name: The name of the scheduler resource.
schedule_pattern: Cron formatted value used to create a Scheduled retrain job.
setup_model_monitoring: Boolean parameter which specifies whether to set up a Vertex AI Model Monitoring Job.
source_repo_branch: The branch to use in the source repository.
source_repo_name: The name of the source repository to use.
source_repo_type: The type of source repository to use (e.g. gitlab, github, etc.)
storage_bucket_location: Region of the GS bucket.
storage_bucket_name: GS bucket name where pipeline run metadata is stored.
hide_warnings: Boolean used to specify whether to show provision/deploy permission warnings
use_ci: Flag that determines whether to use Cloud CI/CD.
vpc_connector: The name of the vpc connector to use.
workload_identity_pool: Pool for workload identity federation.
workload_identity_provider: Provider for workload identity federation.
workload_identity_service_account: Service account for workload identity federation (specify the full string).
"""
generate(
project_id=project_id,
pipeline_params=pipeline_params,
artifact_repo_location=artifact_repo_location,
artifact_repo_name=artifact_repo_name,
artifact_repo_type=artifact_repo_type,
base_image=base_image,
build_trigger_location=build_trigger_location,
build_trigger_name=build_trigger_name,
custom_training_job_specs=custom_training_job_specs,
deployment_framework=deployment_framework,
naming_prefix=naming_prefix,
orchestration_framework=orchestration_framework,
pipeline_job_location=pipeline_job_location,
pipeline_job_runner_service_account=pipeline_job_runner_service_account,
pipeline_job_submission_service_location=pipeline_job_submission_service_location,
pipeline_job_submission_service_name=pipeline_job_submission_service_name,
pipeline_job_submission_service_type=pipeline_job_submission_service_type,
project_number=project_number,
provisioning_framework=provisioning_framework,
provision_credentials_key=provision_credentials_key,
pubsub_topic_name=pubsub_topic_name,
schedule_location=schedule_location,
schedule_name=schedule_name,
schedule_pattern=schedule_pattern,
setup_model_monitoring=setup_model_monitoring,
source_repo_branch=source_repo_branch,
source_repo_name=source_repo_name,
source_repo_type=source_repo_type,
storage_bucket_location=storage_bucket_location,
storage_bucket_name=storage_bucket_name,
use_ci=use_ci,
vpc_connector=vpc_connector,
workload_identity_pool=workload_identity_pool,
workload_identity_provider=workload_identity_provider,
workload_identity_service_account=workload_identity_service_account)
provision(hide_warnings=hide_warnings)
deploy(hide_warnings=hide_warnings, precheck=precheck)