consigliere-fleet-template
The starting point for your private fleet repo: your hosts, your settings, your secrets.
This is the other half of Consigliere. The framework is public and generic and knows nothing about your machines. This repo is where you list them, say what each one runs, and keep the values and encrypted secrets that must stay private.
Status: in testing. It is the template the maintainer’s own fleet was built from, and it moves with the framework. This project comes with no warranty or guarantee of fitness for any purpose. Use it at your own risk.
LLM use. Built and maintained with substantial AI assistance (Claude Code). Design decisions and reviews are by a human; generated changes are reviewed before they are merged.
flowchart TB
accTitle: The two repos
accDescr: The public framework repo and your private fleet repo are both pulled by every host, which checks and applies them on a timer.
subgraph framework["Framework repo · public, you do not edit it"]
roles["<b>Roles</b><br/>what a host can run"]:::blue
tags["<b>Tag manifests</b><br/>which roles a tag runs"]:::blue
roles ~~~ tags
end
subgraph fleet["Your fleet repo · private, says what you run and where"]
table["<b>Host table</b><br/>one row per host"]:::purple
vars["<b>Variables</b><br/>per group, per host"]:::purple
secrets["<b>Secrets</b><br/>sops, per-host keys"]:::purple
table ~~~ vars ~~~ secrets
end
host["<b>Every host</b><br/>pulls both repos about every 20 minutes<br/>checks, applies, skips when nothing is new<br/>decrypts only what its own key was granted"]:::green
fleet --> host
framework --> host
classDef blue fill:#2f6fdb26,stroke:#2f6fdb
classDef purple fill:#7a45c926,stroke:#7a45c9
classDef green fill:#1f8a4c26,stroke:#1f8a4c
style framework fill:transparent,stroke:#2f6fdb
style fleet fill:transparent,stroke:#7a45c9
What it does
Section titled “What it does”It gives you the layout a fleet repo needs: a host table, group and host variables, sops-encrypted secrets, a list of who may read which secret, and a place for your own roles and runbooks. Every host clones this repo and the framework on each reconcile, so the repo has to be private and each host needs read access to it. The framework’s bootstrap script arranges that.
Use cases
Section titled “Use cases”- You have just installed Consigliere and need a private repo to describe your first hosts in.
- You are adding a host and want to know where its tags, variables and secrets go.
Getting started
Section titled “Getting started”A GitHub fork of a public repo cannot be made private, so use the template button (“Use this template”, owner, name, Private), or:
gh repo create <you>/<fleet-name> --private --template almadon/consigliere-fleet-template --clonecd <fleet-name>git config core.hooksPath .githooks # refuses to commit a plaintext secretThen:
- List your hosts in
config/inventory/hosts.yml. The key is the host’s Tailscale hostname. Give each host atype, asite,util(services it provides:util: [traefik]runs the Traefik role) andfeat(agents it runs:feat: [arkeep]runs the Arkeep agent).groups.ymlturns these into groups. Your names never appear in the public framework, and Tailscale tags are not used for grouping. - Replace every
CHANGEMEinconfig/vars/, then create the secrets you need withscripts/secrets.sh create <scope>(see Secrets below). - Run
scripts/preflight.sh --strict. It should pass before you push.
Deploy a host
Section titled “Deploy a host”On the host (Debian), with the framework’s hosts/bootstrap/bootstrap.sh:
FRAMEWORK_REPO_URL=https://github.com/almadon/Consigliere.git \FLEET_CONFIG_REPO_URL=git@github.com:<you>/<fleet-name>.git \FLEET_CONFIG_REGISTER_TOKEN=<token> \ # optional, see below./bootstrap.shThe framework makes sure the host can read this repo: it generates a
read-only deploy key on the host (the private half never leaves it). With
FLEET_CONFIG_REGISTER_TOKEN (a GitHub token allowed to manage this repo’s
deploy keys; used once, never stored) it registers the key for you. Without
it, the script prints the public key, and you add it under Settings → Deploy
keys (read-only); the script waits and continues once it works. It then prints the host’s age public key for you to grant (see
Secrets). The first run is check-only; you approve the apply.
Secrets
Section titled “Secrets”Secrets are named files encrypted with sops
(age keys). A scope <kind>.<name> is the file config/secrets/<kind>/<name>.yml.
Each file is encrypted to the public keys of you (the admins) and of exactly the hosts
allowed to read it, so a host can decrypt only its own files, with a private key that
never leaves it. There are no shared passwords. Folders go big to small:
| Scope | File | Read by |
|---|---|---|
arkeep.agent |
config/secrets/arkeep/agent.yml |
Arkeep server and agents (shared secret) |
arkeep.server |
config/secrets/arkeep/server.yml |
the Arkeep server only |
arcane.server |
config/secrets/arcane/server.yml |
the Arcane manager, if Ansible deploys it |
semaphore.server |
config/secrets/semaphore/server.yml |
the Semaphore host |
cw.<name> |
config/secrets/cw/<name>.yml |
hosts with cert: [<name>] |
Who can read what is derived from the host table. Each tag manifest in the
framework (hosts/tags/) lists the secrets: its roles need (cert: values become
cw.<value>). So adding util: [arkeep] to a host in hosts.yml and running
scripts/access.sh sync grants it the Arkeep secrets; removing the tag and syncing
revokes it. scripts/access.sh show prints the table. Secrets no tag implies go under
extra_grants in config/access.yml.
Setting up (once, on your admin machine): install sops and age, then
scripts/secrets.sh init-admin # your age key (~/.config/sops/age/keys.txt) + registers you(back that key up; with no admin key left, nothing can be re-encrypted). Set
framework_dir in config/access.yml (or CONSIGLIERE_DIR) to your checkout of the
framework, which access.sh reads for the manifests.
Everyday:
scripts/secrets.sh create arkeep.agent # new file from its .example, encryptedscripts/secrets.sh edit arkeep.agent # nano; re-encrypts on savescripts/secrets.sh decrypt arkeep.agent # decrypt IN PLACE to edit in an IDE ...scripts/secrets.sh encrypt arkeep.agent # ... then encrypt again (preflight refuses to commit plaintext)Adding a host: bootstrap.sh generates the host’s age key and prints its public half.
Then, here: scripts/access.sh add-host <name> <key>, scripts/access.sh sync, commit,
push. Removing a host: scripts/access.sh remove-host <name>, sync, push, and
scripts/secrets.sh rotate <scope> plus changing the actual secret values it could read
(it has seen them). scripts/preflight.sh (also the pre-commit hook) checks that every
secret is encrypted and that .sops.yaml is up to date. Note that every host clones all
the ciphertext; the recipient lists decide what each can open.
Tailscale auth keys are never stored: bootstrap.sh prompts for one.
How it works
Section titled “How it works”config/ inventory/hosts.yml the host table: every host + type/site/util/feat. Required. inventory/groups.yml turns the table's values into groups. Required. vars/group/*.yml values per group (server address, ports, ...) vars/group/*.yml.example opt-in settings for cmdr, Loki, VictoriaMetrics, Grafana and the otel agent: rename to enable vars/host/<host>.yml per-host values (e.g. an Arcane agent token) routes/<domain>.yml Traefik routes, one file per domain (start from routes/example.com.yml.example) secrets/<kind>/<name>.yml sops-encrypted secrets (see Secrets) access.yml admin and host age public keys (managed by scripts/access.sh) site.yml.example optional: rename to site.yml to choose which roles run where roles/ optional: your own roles/appsrunbooks/ procedures; the ones here are generic, add your ownscripts/ helpers, listed in runbooks/admin-scripts.md and runbooks/cli-reference.mdThe scripts you will reach for most: secrets.sh and access.sh (secrets and who can read them), preflight.sh (checks before you push), reconcile-now.sh (reconcile hosts now instead of waiting), fleet-run.sh (run a command or update hosts), publish.sh and routes_check.py (Traefik routes), and tag.sh (add or remove a tag on hosts).
Credits
Section titled “Credits”This repo is a layout and a few helper scripts. The work is done by Consigliere and the software it drives, listed with links and licences in its credits. The secrets handling here is sops with age keys, and the Cert Warden helper script talks to Cert Warden.
Documentation
Section titled “Documentation”| Read | For |
|---|---|
| docs/README.md | State, architecture, ownership, security, decisions and credits for this repo |
| Framework README | What Consigliere manages and what it leaves alone |
| runbooks/README.md | The runbooks: adding a node, publishing a service, cmdr, run reporting, exposure watch and the script reference |
| Framework docs/security.md | Trust boundaries and how secrets are handled |
| Framework docs/ownership.md | What each thing is owned by, and how to roll it back |
Development
Section titled “Development”Work on a branch and open a pull request. Run git config core.hooksPath .githooks once, so the preflight and the commit message check run before each commit. The checks are listed in AGENTS.md.
Keeping up with the template
Section titled “Keeping up with the template”This is a starting point, not a live link: later changes to the template don’t flow into your repo. When the framework adds a role with new settings, its docs say which variables to add here.
License
Section titled “License”MIT, like the framework. A private fleet repo made from this template is yours: replace the LICENSE file with whatever you want it to say, for example that it is private and not licensed for reuse.