How To

Migrating from Steampipe to Powerpipe

Play your favorite Steampipe hits, and enjoy some new ones.

Turbot Team
5 min. read - March 6, 2024

Steampipe users have enjoyed the built-in dashboards-as-code features since Steampipe CLI v0.13. With Powerpipe we wanted to make those same features available for other databases. That's one reason we've decoupled dashboards from the Steampipe CLI and dashboard server: so you can use Powerpipe with your own database.

Powerpipe includes the 43 Steampipe mods to visualize AWS, Azure, GCP, GitHub, Terraform and more. And nine ready-to-use Powerpipe mods show you how to visualize data in Postgres, SQLite, DuckDB, and MySQL!

If you're using Steampipe today to run dashboards and/or benchmarks, that all still works, but over time we'll deprecate these uses of Steampipe in favor of Powerpipe.

Powerpipe extends your Steampipe superpowers: it's database-agnostic, with dashboards that filter and group. Of course it also does what you've always been doing.

Run Steampipe as usual

Let's assume you've installed Steampipe along with AWS plugin and are running Steampipe as a service (steampipe service start).

Add Powerpipe

Now you install Powerpipe.

Here are some common operations in Steampipe along with their Powerpipe counterparts.

Run a dashboard

actionSteampipePowerpipe
Install AWS Insightssteampipe mod install github.com/turbot/steampipe-mod-aws-insightspowerpipe mod install github.com/turbot/steampipe-mod-aws-insights
Start dashboard serversteampipe dashboardpowerpipe server
Browse to dashboardshttp://localhost:9194http://localhost:9033

See Powerpipe dashboards for details.

Run a benchmark

actionSteampipePowerpipe
Install AWS Compliancesteampipe mod install github.com/turbot/steampipe-mod-aws-compliancepowerpipe mod install github.com/turbot/steampipe-mod-aws-compliance
Start dashboard serversteampipe dashboardpowerpipe server
Browse to dashboardshttp://localhost:9194http://localhost:9033
Run a benchmark in your terminalsteampipe check benchmark.cis_v300powerpipe benchmark run cis_v300

See Running benchmarks for details.

Run a query

actionSteampipePowerpipe
List queriessteampipe query listpowerpipe query list
Run named querysteampipe query query_namepowerpipe query query_name
Run literal querysteampipe query "sql statement"powerpipe query run "sql statement"

See Powerpipe query for details.

File extensions

extensionSteampipePowerpipe
HCL code for a mod.sp.pp
Config info.spc.ppc
Snapshots.sps.pps
Variables.spvars.ppvars

See dashboards, benchmarks, and config files for details.

Environment variables

SteampipePowerpipe
STEAMPIPE_LOG_LEVELPOWERPIPE_LOG_LEVEL
STEAMPIPE_MAX_PARALLELPOWERPIPE_MAX_PARALLEL
PIPES_TOKENPIPES_TOKEN

Many variables carry over from Steampipe, but Powerpipe adds new ones like POWERPIPE_DATABASE. See Powerpipe Environment Variables for details.

Passing input variables

SteampipePowerpipe
steampipe query --var=instance_state="running"powerpipe query --var=instance_state="running"
steampipe check all --var-file='tags.spvars'powerpipe benchmark run all --var-file='tags.ppvars'

See Passing Input Variables for more examples.

Change databases

Powerpipe defaults to a local Steampipe instance (postgres://steampipe@127.0.0.1:9193/steampipe) but you can change to another database in several ways.

Using --database

powerpipe benchmark run cis_v120 --database postgres://myusername:passworrd@mydbserver.mydomain.com:9193/steampipe

or

powerpipe server --database postgres://myusername:passworrd@mydbserver.mydomain.com:9193/steampipe

See Selecting a database for more examples.

Using a workspace

workspace "my_workspace" {
database = "postgres://my_username:passsord@db1.jpeterman.com:5432/steampipe"
}

or

workspace "my_workspace" {
database = "sqlite:./my_sqlite.db"
}

See Managing workspaces for more examples.

Use the Powerpipe Hub

The Steampipe Hub will redirect you to the Powerpipe Hub where, under a fresh coat of paint, you'll find all your favorite mods.

Read the Powerpipe docs

The Steampipe docs are also spruced up at powerpipe.io/docs.

Enjoy the upgrade!

Rest assured that all v0.x versions of Steampipe mods will work in both Steampipe and Powerpipe. But note that from v1.0.0 onward, mods will be in Powerpipe format only.

Once you're settled in, we encourage you to try a few things. If you run benchmarks, turn on filters and grouping to slice and dice your benchmark results. If you build dashboards, check out some of the new mods that work with non-Steampipe databases and schemas. And as always, let us know your thoughts.