prefect_gcp.models.cloud_run_v2
Classes
SecretKeySelector
SecretKeySelector is a data model for specifying a GCP secret to inject
into a Cloud Run V2 Job as an environment variable.
Follows Cloud Run V2 rest API, docs:
https://cloud.google.com/run/docs/reference/rest/v2/Container#SecretKeySelector
JobV2
JobV2 is a data model for a job that will be run on Cloud Run with the V2 API.
Methods:
create
cr_client: The base client needed for interacting with GCP Cloud Run V2 API.project: The GCP project ID.location: The GCP region.job_id: The ID of the job to create.body: The job body.
- The response from the Cloud Run V2 API.
delete
cr_client: The base client needed for interacting with GCP Cloud Run V2 API.project: The GCP project ID.location: The GCP region.job_name: The name of the job to delete.
- The response from the Cloud Run V2 API.
get
cr_client: The base client needed for interacting with GCP Cloud Run V2 API.project: The GCP project ID.location: The GCP region.job_name: The name of the job to get.
get_ready_condition
- The ready condition for the job.
is_ready
- Whether the job is ready to run.
run
cr_client: The base client needed for interacting with GCP Cloud Run V2 API.project: The GCP project ID.location: The GCP region.job_name: The name of the job to run.
ExecutionV2
ExecutionV2 is a data model for an execution of a job that will be run on
Cloud Run API v2.
Methods:
condition_after_completion
- The condition after completion.
get
cr_client: The base client needed for interacting with GCP Cloud Run V2 API.execution_id: The name of the execution to get, in the form of projects//locations//jobs//executions /
is_running
- Whether the execution is running.