steampipe plugin install fastly

Table: fastly_condition - Query Fastly Conditions using SQL

Fastly Conditions are logical expressions that specify when a particular behavior should be triggered in Fastly's Content Delivery Network (CDN) service. Conditions are used to control how and when certain actions are executed within Fastly. They are associated with specific Fastly services and can be used in various configurations like caching, routing, and response manipulation.

Table Usage Guide

The fastly_condition table provides insights into the conditions configured within Fastly Content Delivery Network (CDN). As a site reliability engineer, explore condition-specific details through this table, including its type, statement, and associated service. Utilize it to uncover information about conditions, such as those used for caching policies, routing rules, or response manipulations.

Examples

Basic info

Explore the fundamental details of specific conditions within your Fastly service to understand their priority and creation time. This could be particularly useful for auditing and managing your service configurations effectively.

select
name,
service_id,
service_version,
type,
priority,
created_at
from
fastly_condition;
select
name,
service_id,
service_version,
type,
priority,
created_at
from
fastly_condition;

List conditions that are not deleted

Explore conditions within your Fastly service configuration that are still active and have not been deleted. This allows you to review and manage your current settings and priorities effectively.

select
name,
service_id,
service_version,
type,
priority,
created_at
from
fastly_condition
where
deleted_at is null;
select
name,
service_id,
service_version,
type,
priority,
created_at
from
fastly_condition
where
deleted_at is null;

List conditions that are of 'CACHE' type

Explore which conditions in your Fastly configuration are set to 'CACHE' type. This can help in managing cache behavior and troubleshooting caching issues.

select
name,
service_id,
service_version,
type,
priority,
created_at
from
fastly_condition
where
type = 'CACHE';
select
name,
service_id,
service_version,
type,
priority,
created_at
from
fastly_condition
where
type = 'CACHE';

List conditions that are of high priority

Explore which conditions within the Fastly service are marked as high priority. This can be useful in identifying areas that require immediate attention or action.

select
name,
service_id,
service_version,
type,
priority,
created_at
from
fastly_condition
where
priority = 1;
select
name,
service_id,
service_version,
type,
priority,
created_at
from
fastly_condition
where
priority = 1;

Schema for fastly_condition

NameTypeOperatorsDescription
_ctxjsonbSteampipe context in JSON form, e.g. connection_name.
commenttextA freeform descriptive note.
created_attimestamp with time zoneTimestamp (UTC) of when the condition was created.
deleted_attimestamp with time zoneTimestamp (UTC) of when the condition was deleted.
nametext=Name of the condition.
prioritybigintPriority determines execution order. Lower numbers execute first.
service_idtextAlphanumeric string identifying the service.
service_versionbigintInteger identifying a service version.
statementtextA conditional expression in VCL used to determine if the condition is met.
titletextTitle of the resource.
typetextType of the condition.
updated_attimestamp with time zoneTimestamp (UTC) of when the condition was updated.

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)" -- fastly

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

steampipe_export_fastly --config '<your_config>' fastly_condition