cinc is a single, unified command-line tool for Cinc Infra (with full
Chef Infra compatibility) — one command with one consistent grammar. It
is a Go binary built with
Cobra on top of the
cinc-api client library, which owns
authentication and transport.
Early development. The command surface is being built out one noun
group at a time. See docs/commands/cinc.md
for the current command surface (auto-generated from the cobra command
tree). The taxonomy and internal architecture are described in
docs/dev/.
Requires Go 1.26 or newer.
# Build a local ./cinc binary
make build
# Or install into $GOBIN
make installmake injects version, commit, and build-date metadata into the binary
via -ldflags; cinc version will print them.
cinc reads a TOML credentials file (default ~/.cinc/credentials)
holding named profiles, in the same shape as Chef's ~/.chef/credentials.
Each top-level section is a profile that points at one Cinc/Chef Server.
[default]
cinc_server_url = "https://cinc.example.com/organizations/acme"
client_name = "tim"
client_key = "/keys/tim.pem"
[staging]
cinc_server_url = "https://staging.example.com/organizations/acme-staging"
client_name = "tim"
client_key = "/keys/staging.pem"
ssl_verify_mode = ":verify_none"Persistent flags on every command:
| Flag | Description |
|---|---|
--config |
Path to the credentials file (default ~/.cinc/credentials) |
--profile |
Profile name to use (default: $CINC_PROFILE, then $CHEF_PROFILE, then default) |
--format |
Output format: human or json |
Every chef-prefixed config key and environment variable has a
cinc-prefixed equivalent. Both are accepted; if both are set in the same
profile or environment the cinc_/CINC_ form wins. This lets you run
cinc against an existing Chef setup unchanged, and override individual
settings without rewriting the whole file.
| Chef-prefixed | Cinc-prefixed |
|---|---|
chef_server_url (TOML key) |
cinc_server_url (TOML key) |
CHEF_PROFILE (env var) |
CINC_PROFILE (env var) |
Commands are noun-verb. The core verbs (list, show, create,
edit, delete) mean the same thing on every noun. For a guided
walkthrough — profiles, output formats, common workflows — see
docs/README.md. For the exhaustive per-command
reference (every flag, every default), see
docs/commands/. The reference pages are
regenerated from the live cobra command tree by make docs and
refreshed automatically on every push to main.
make test # unit tests
make vet # go vet
make fmt # gofmt -w
make test-acceptance # acceptance tests against chef-zero (needs Ruby + chef-zero gem)
make help # list all targetsRepository layout:
apps/cinc/— the binary.cinc.gois a thinmain();cmd/holds the Cobra command tree (one file per noun group, plusroot.goand flag-resolution helpers incommon.go).cli/config— TOML config parsing and profile resolution.cli/client— builds acinc-apiclient from a resolved profile. This is the single seam between CLI state and the API library; the CLI itself never builds or signs an HTTP request.cli/printer— renders command output as human text or JSON.docs/— auto-generated per-command reference undercommands/(regenerated bymake docs) and design docs underdev/.tools/gendocs/— small Go program that walks the cobra command tree and writes the Markdown reference. Invoked bymake docs.test/— acceptance tests, gated behind theacceptancebuild tag.
See CLAUDE.md for conventions followed when developing
with Claude Code.