Fetcher 配置

后端选项

backend 是在配置文件 [fetcher] 部分中指定的通用选项。默认值为 keystone,用于指定用于获取评级范围列表的驱动程序。

Fetcher 特定选项

Fetcher 特定选项必须在 cloudkitty.conffetcher_{fetcher_name} 部分中指定。

Gnocchi

Section fetcher_gnocchi

  • scope_attribute:默认为 project_id。应收集 scope_ids 的属性。

  • resource_types:默认为 [generic]。gnocchi 资源类型列表。如果留空则全部。

  • gnocchi_auth_type:默认为 keystone。定义 gnocchi fetcher 应使用哪种身份验证方法。必须是 basic(用于 gnocchi 基本身份验证)或 keystone(用于经典 keystone 身份验证)之一。如果选择 keystone,则可以在 auth_section 参数指向的部分中指定凭据。

  • gnocchi_user:仅用于 gnocchi 基本身份验证。gnocchi 用户。

  • gnocchi_endpoint:仅用于 gnocchi 基本身份验证。gnocchi 端点。

  • interface:默认为 internalURL。仅用于 keystone 身份验证。用于 keystone URL 发现的接口。

  • region_name:默认为 RegionOne。仅用于 keystone 身份验证。区域名称。

Keystone

Section fetcher_keystone

  • keystone_version:默认为 3。要使用的 Keystone 版本。

  • auth_section:如果定义了 auth_section 选项,则将使用目标部分中声明的所有选项,以便通过 Keystone 服务获取范围。

如果未定义 auth_section 选项,则可以使用此处找到的常规 Keystone 身份验证选项来配置 Keystone fetcher:分步配置指南

  • ignore_rating_role:如果设置为 true,Keystone fetcher 将不会检查项目是否具有评级角色;因此,CloudKitty 将对它找到的每个项目执行评级。默认为 false。

  • ignore_disabled_tenants:如果设置为 true,Cloudkitty 将不会评级在 Keystone 中禁用的项目。默认为 false。

Prometheus

Section fetcher_prometheus

  • metric:应请求 scope_ids 的指标。

  • scope_attribute:默认为 project_id。应请求 scope_ids 的属性。

  • filters:可选的键值字典,用于使用其他元数据来过滤一些 Prometheus 服务响应。

  • prometheus_url:Prometheus HTTP API URL。

  • prometheus_user:用于 HTTP 基本身份验证。用户名。

  • prometheus_password:用于 HTTP 基本身份验证。密码。

  • cafile:允许自定义证书颁发机构文件的选项。

  • insecure:显式允许不受信任的 HTTPS 连接的选项。

来源

Section fetcher_source

  • sources:scope_ids 的显式列表。