# 使用 Homebrew, Nix 安装 grafanactl

查看 grafanactl 的安装路径、可执行文件、元数据以及面向 AI 代理工作流的安全说明。

## 安装

```sh
sudo av install brew:grafanactl
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install grafanactl
```

  证据: local Homebrew formula metadata

### Linux

- Nix (92%):

```sh
nix profile install nixpkgs#grafanactl
```

  证据: nixpkgs package indexes: pkgs/by-name/gr/grafanactl/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

## 软件包事实

- **软件包键:** brew:grafanactl
- **软件包管理器:** Homebrew
- **版本:** 0.1.10
- **来源摘要:** CLI to interact with Grafana
- **主页:** <https://grafana.github.io/grafanactl/>
- **仓库:** <https://github.com/grafana/grafanactl>
- **最后更新:** 2026-07-29T16:05:05+02:00
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- grafanactl (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

- 页面生成时间: 2026-08-03
- 管理器版本: 0.1.10
## 项目历史与用法

grafanactl is a Grafana Labs command-line tool for managing Grafana resources and environments through Grafana APIs. It belongs to the observability-as-code layer around Grafana rather than to the Grafana server itself.

### 项目历史

The Grafana documentation presents grafanactl as a CLI for authentication, multiple environments, and administrative/resource workflows through the Grafana REST API. The repository README describes it as public-preview software used by Grafana Labs while still under active development.

By 2026 the repository README pointed users toward gcx as the successor CLI and said the grafanactl repository would be archived on June 1, 2026. That makes grafanactl a transitional package in the Grafana CLI lineage.

### 采用历史

grafanactl adoption is tied to teams treating Grafana configuration as code: backing up resources, restoring resources, serving local resource definitions, and switching contexts between Grafana instances. Its Homebrew package gives macOS users a simple binary install for that workflow.

### 使用方式

Users configure contexts, authenticate to Grafana, and run resource commands such as pulling resources to YAML or serving resources locally for preview and migration workflows.

### 为什么软件包爱好者会关心

grafanactl is significant as a small, purpose-built companion CLI: it packages Grafana API automation separately from the large Grafana server package, which keeps scripted resource management available in shells and CI jobs.

### 时间线

- 2026-04-27: GitHub release page listed v0.1.10.
- 2026-06-01: Repository README named this date for archival in favor of gcx.

### Related projects

- Grafana is the server and API target.
- gcx is the successor CLI named by the Grafana repository.
- Grafana App SDK resources are part of the ecosystem around resource management.

### 来源

- <https://github.com/grafana/grafanactl>
- <https://grafana.com/docs/grafana/latest/as-code/observability-as-code/grafana-cli/grafanacli-workflows/>
- <https://grafana.com/docs/grafana/latest/as-code/observability-as-code/grafana-cli/grafanactl/>
- <https://grafana.github.io/grafanactl/reference/cli/grafanactl/>


## 安全说明

narrow executable package without higher-risk signals.

- **Geiger 风险:** 绿色 / 低
- narrow executable package without higher-risk signals


## Configuration and credential file locations

These source-backed paths show where this package keeps local settings or durable credentials. Automic Vault can use them as review targets for secret scanning, migration, and command approval.


## Configuration files

- Unix: $XDG_CONFIG_HOME/grafanactl/config.yaml, ~/.config/grafanactl/config.yaml

## Credential files

- Unix: $XDG_CONFIG_HOME/grafanactl/config.yaml, ~/.config/grafanactl/config.yaml
## 其他软件包管理器记录

- Nix - grafanactl: normalized package name match | nixpkgs package indexes: pkgs/by-name/gr/grafanactl/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1


## Combined YAML source

View the package source record on GitHub. [combined/grafanactl.yml](https://github.com/mxcl/pkgdb/blob/main/combined/grafanactl.yml)


## 来源

- pkg.so package database
- Geiger risk classifier
- curated configuration and credential file locations
- curated package history
- pkgdb category and tag curation
- external package-manager database matches
- cross-ecosystem install command graph
