chore(turbot-pipes): continue learning

This commit is contained in:
Michele Cereda
2024-05-24 13:13:22 +02:00
parent e22c5a4043
commit d3d6f38a97
3 changed files with 94 additions and 32 deletions

View File

@@ -1,31 +1,7 @@
# Turbot pipes
<!-- Remove this line to uncomment if needed
## Table of contents <!-- omit in toc -->
1. [TL;DR](#tldr)
1. [Further readings](#further-readings)
## TL;DR
<!-- Uncomment if needed
<details>
<summary>Installation and configuration</summary>
</details>
-->
<!-- Uncomment if needed
<details>
<summary>Usage</summary>
</details>
-->
<!-- Uncomment if needed
<details>
<summary>Real world use cases</summary>
</details>
-->
## Further readings
- [Website]
@@ -33,19 +9,20 @@
- [Powerpipe]
- [Steampipe]
Alternatives:
- [CloudQuery]
<!--
Reference
═╬═Time══
-->
<!-- In-article sections -->
<!-- Knowledge base -->
[cloudquery]: ../cloudquery.md
[flowpipe]: flowpipe.md
[powerpipe]: powerpipe.md
[steampipe]: steampipe.md
<!-- Files -->
<!-- Upstream -->
[website]: https://turbot.com/pipes
<!-- Others -->

View File

@@ -3,6 +3,7 @@
Dynamically query APIs, code and more with SQL.
1. [TL;DR](#tldr)
1. [Export CLIs](#export-clis)
1. [Further readings](#further-readings)
1. [Sources](#sources)
@@ -16,8 +17,8 @@ Default files directory (called _installation directory_ by Steampipe) is `$HOME
```sh
brew install 'turbot/tap/steampipe'
steampipe completion fish | source
steampipe completion fish > "$HOME/.config/fish/completions/steampipe.fish"
steampipe completion 'fish' | source
steampipe completion 'fish' > "$HOME/.config/fish/completions/steampipe.fish"
# Disable telemetry.
export STEAMPIPE_TELEMETRY='none'
@@ -27,6 +28,7 @@ export STEAMPIPE_TELEMETRY='none'
# These are set to their defaults.
export \
STEAMPIPE_INSTALL_DIR="${HOME}/.steampipe" \
STEAMPIPE_LOG_LEVEL="WARN" \
STEAMPIPE_MAX_PARALLEL=10 \
STEAMPIPE_MOD_LOCATION="$PWD" \
STEAMPIPE_UPDATE_CHECK=true
@@ -116,6 +118,59 @@ Dashboards and Mods have been deprecated in favour of [Powerpipe]. Use it instea
</details>
## Export CLIs
Every Steampipe plugin is distributed as a distinct Steampipe Export CLI.<br/>
It is available for download in the Releases page for the corresponding plugin's repository.
Download, extract, and install the file.<br/>
An install script is available for ease of use:
```sh
$ /bin/sh -c "$(curl -fsSL https://steampipe.io/install/export.sh)"
Enter the plugin name: aws
Enter the version (latest):
Enter location (/usr/local/bin):
Created temporary directory at /var/folders/t4/1lm46wt12sv7yq1gp1swn3jr0000gn/T/tmp.RpZLlzs2.
Downloading steampipe_export_aws.darwin_arm64.tar.gz...
######################################################################### 100.0%
Deflating downloaded archive
x steampipe_export_aws
Installing
Applying necessary permissions
Removing downloaded archive
steampipe_export_aws was installed successfully to /usr/local/bin
```
The output can be in CSV (default), JSON or [JSONL](https://jsonlines.org/).
```sh
$ steampipe_export_aws 'aws_account' --output 'json'
2024/05/24 12:03:53 [INFO] Memoize getBaseClientForAccountUncached
2024/05/24 12:03:53 [INFO] Memoize 0x109fed0c0 listRegionsForServiceUncached
[{
"_ctx": "{\"connection_name\":\"aws\",\"steampipe\":{\"sdk_version\":\"5.10.0\"}}",
"account_aliases": "[\"exampleOrg\"]",
"account_id": "012345678901",
"akas": "[\"arn:aws:::012345678901\"]",
"arn": "arn:aws:::012345678901",
"organization_arn": "arn:aws:organizations::012345678901:organization/o-p42ybyw9ml",
"organization_available_policy_types": "[{\"Status\":\"ENABLED\",\"Type\":\"SERVICE_CONTROL_POLICY\"}]",
"organization_feature_set": "ALL",
"organization_id": "o-p42ybyw9ml",
"organization_master_account_arn": "arn:aws:organizations::012345678901:account/o-p42ybyw9ml/012345678901",
"organization_master_account_email": "user@example.org",
"organization_master_account_id": "012345678901",
"partition": "aws",
"region": "global",
"sp_connection_name": "aws",
"sp_ctx": "{\"connection_name\":\"aws\",\"steampipe\":{\"sdk_version\":\"5.10.0\"}}",
"title": "exampleOrg"
}]
```
## Further readings
- [Website]
@@ -123,6 +178,8 @@ Dashboards and Mods have been deprecated in favour of [Powerpipe]. Use it instea
- [Steampipe unbundled]
- [Flowpipe]
- [Powerpipe]
- [Steampipe and Postgres]
- [Connecting Steampipe with Google BigQuery]
### Sources
@@ -134,13 +191,11 @@ Dashboards and Mods have been deprecated in favour of [Powerpipe]. Use it instea
═╬═Time══
-->
<!-- In-article sections -->
<!-- Knowledge base -->
[flowpipe]: flowpipe.md
[powerpipe]: powerpipe.md
[turbot pipes]: README.md
<!-- Files -->
<!-- Upstream -->
[documentation]: https://steampipe.io/docs
[github]: https://github.com/turbot/steampipe
@@ -148,3 +203,5 @@ Dashboards and Mods have been deprecated in favour of [Powerpipe]. Use it instea
[website]: https://steampipe.io/
<!-- Others -->
[connecting steampipe with google bigquery]: https://briansuk.medium.com/connecting-steampipe-with-google-bigquery-ae37f258090f
[steampipe and postgres]: https://www.reddit.com/r/aws/comments/uh8w9k/steampipe_and_postgres/