separate search_path
for client
and service
. Support search_path_prefix for client
#353
Labels
enhancement
New feature or request
See search path section of https://github.com/turbotio/osquery-extensions/wiki/Steampipe-mods-&-workspaces
Setting the search path
By default, the search path puts the
public
schema first, followed by all connection schemas, ordered alphabetically.You may change the default in the steampipe config file in the
database
options. This will change the search path in the database. This means that this path will be the default even when connecting to the Steampipe database from 3rd party tools.You may also change the default in the
terminal
options. This will change the search path for the session when connecting via Steampipe, but it does NOT change the setting in the database; the search path set interminal
options will NOT be in effect when connecting directly to the Steampipe database from 3rd party tools.You may set the
terminal
options globally (in~/.steampipe/config/default.spc
), and the setting will override the database level setting when using Steampipe. You may also set the search path on a per-workspace basis in theworkspace.spc
file; if set, the workspace setting will override any global setting.Alternatively, you may use
search_path_prefix
in theterminal
options. Thesearch_path
is a comma-separated list of connection names that will define the exact search path.search_path_prefix
is also a comma separated list of connections, but it used to move connections to the front of the search path. This is useful when you want to prefer a specific connection for one or more plugin types, but to still include the rest in the search path. For instance, I may have manyaws
connections, and I would like to preferaws01
in my workspace but still leave all the other connections (github
,slack
,shodan
, etc) in the search path as well. While this is possible usingsearch_path
, you would need to update thesearch_path
every time you install a new plugin. This is simple and dynamic, however, when usingsearch_path_prefix
:You may override the config file settings with the
--search-path
or--search-path-prefix
command line arguments:steampipe query --search_path "aws_account1,gcp,azure,github"
aws01
andgcp01
connections to the front of the search path:steampipe query --search-path-prefix "aws01,gcp01"
You can also set the search path for the duration of your interactive session with a the
.search_path
or.search_path_prefix
meta-commands. These settings will last for the duration of the session, and behave the same as thesearch_path
andsearch_path_prefix
options:aws01
andgcp01
connections to the front of the search path:You can view your current active search path by issuing the
.search_path
meta-command with no arguments> .search_path public, alicloud, aws, aws_01, aws_02, aws_03, azure, azure_01, digitalocean, gcp, github, hackernews, ipstack, kubernetes, oci, public, rss, slack, steampipe, whois, zendesk, internal
The text was updated successfully, but these errors were encountered: