Skip to main content

dbt Artifact Storage: Google Cloud Storage Configuration

This guide walks you through configuring Google Cloud Storage (GCS) as the artifact storage layer for dbt Core + OpenMetadata integration. Perfect for Google Cloud Platform deployments.

Prerequisites Checklist

Step 1: GCS Setup

1.1 Create GCS Bucket

Expected output:

1.2 Create Service Account for dbt (Write Access)

Your dbt environment needs permission to write to GCS.
Store the service account key securely. Never commit it to version control.

1.3 Create Service Account for OpenMetadata (Read Access)

OpenMetadata needs permission to read from GCS.

1.4 (Alternative) Use Workload Identity on GKE

If running on GKE, use Workload Identity instead of service account keys:

1.5 Verify GCS Access

Step 2: Upload Artifacts from dbt

2.1 Understanding dbt Artifacts

OpenMetadata requires these dbt-generated files: Generate all artifacts:

2.2 Complete Cloud Composer DAG

This is a complete, working DAG for Cloud Composer or GKE-based Airflow. Save as dbt_with_gcs.py in your Cloud Composer DAGs folder:

2.3 Alternative: Simple gsutil Upload

For simpler setups, use gsutil directly in a BashOperator:

2.4 Verify DAG Deployment

Expected output:

Step 3: Configure OpenMetadata

Configuration

  1. Go to Settings → Services → Database Services
  2. Click on your database service (e.g., “production-bigquery”)
  3. Go to the Ingestion tab
  4. Click Add Ingestion
  5. Select dbt from the dropdown
Configure dbt Source (GCS): GCP Credentials: Upload the OpenMetadata service account key JSON:
  1. Click Upload Credentials
  2. Select ~/collate-sa-key.json
  3. Or paste the JSON content directly
Configure dbt Options: Test & Deploy:
  1. Click Test Connection
  2. If successful, click Deploy
  3. Click Run to trigger immediately

Verification

After running the full pipeline, verify:

Cloud Composer Specific Setup

Upload Service Account Key to Composer

Set Environment Variables

Troubleshooting

Next Steps

See other storage options: S3 | Azure | HTTP | Local | dbt Cloud