Vertex AI
Vertex AI uses Google Application Default Credentials (ADC). The runner
points GOOGLE_APPLICATION_CREDENTIALS at the mounted service-account
key file.
apiVersion: v1kind: Secretmetadata: name: vertex-credentialstype: Opaquedata: # key name MUST be GOOGLE_APPLICATION_CREDENTIALS; value is a # base64-encoded JSON service account key. GOOGLE_APPLICATION_CREDENTIALS: <base64>---apiVersion: genkit.dev/v1alpha1kind: PluginConfigmetadata: name: vertexaispec: type: vertexai region: us-central1 credentialsRef: name: vertex-credentials extraConfig: projectId: my-gcp-project # location takes precedence over the top-level region field # location: us-central1---apiVersion: genkit.dev/v1alpha1kind: Modelmetadata: name: gemini-2-prospec: provider: vertexai model: gemini-2.0-pro pluginConfigRef: name: vertexaiCredentials
Section titled “Credentials”| Default key | Notes |
|---|---|
GOOGLE_APPLICATION_CREDENTIALS | Path to the SA key; the runner sets the env var for the SDK |
extraConfig
Section titled “extraConfig”| Field | Type | Description |
|---|---|---|
projectId | string | GCP project ID |
location | string | GCP region; overrides top-level region |
Reference
Section titled “Reference”genkit-goplugin:go/plugins/googlegenai- Models on Vertex:
cloud.google.com/vertex-ai/generative-ai/docs/learn/models