steampipe plugin install gcp

Table: gcp_tag_binding - Query GCP Tag Bindings using SQL

Google Cloud's Tag Manager allows users to attach metadata to GCP resources in the form of tags. Tags are key-value pairs that help in organizing and managing resources, such as VM instances, storage buckets, and networks. Tag bindings are the association between a tag and a resource, which allows users to filter and manage resources based on their metadata.

Examples

Basic info

Explore which resources are tagged within your Google Cloud Platform, gaining insights into the associated tags and resource types. This can be particularly useful for managing and organizing your resources.

select
name,
parent,
tag_value,
title
from
gcp_tag_binding
where
parent = '//cloudresourcemanager.googleapis.com/projects/your-project-id';
select
name,
parent,
tag_value,
title
from
gcp_tag_binding
where
parent = '//cloudresourcemanager.googleapis.com/projects/your-project-id';

Schema for gcp_tag_binding

NameTypeOperatorsDescription
_ctxjsonbSteampipe context in JSON form, e.g. connection_name.
nametextThe name of the TagBinding. This is a string of the form: `tagBindings/{full-resource-name}/{tag-value-name}`.
parenttext=The full resource name of the resource the TagValue is bound to.
projecttextThe GCP Project in which the resource is located.
tag_valuetextThe TagValue of the TagBinding. Must be of the form `tagValues/456`.
tag_value_namespaced_nametextThe namespaced name for the TagValue of the TagBinding.
titletextTitle of the resource.

Export

This table is available as a standalone Exporter CLI. Steampipe exporters are stand-alone binaries that allow you to extract data using Steampipe plugins without a database.

You can download the tarball for your platform from the Releases page, but it is simplest to install them with the steampipe_export_installer.sh script:

/bin/sh -c "$(curl -fsSL https://steampipe.io/install/export.sh)" -- gcp

You can pass the configuration to the command with the --config argument:

steampipe_export_gcp --config '<your_config>' gcp_tag_binding