netbox-facts: decide token source (no host->Vault auth exists) #518
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Context
profiles::netbox::factsseeds/etc/puppetlabs/netbox.tokenfrom hieraprofiles::netbox::facts::api_token, and thenetboxfact authenticates to NetBox with that static token. Thevault-plugin-secrets-netboxengine is now live and mints per-consumer ephemeral NetBox tokens; terraform-vault adds a read-onlynetbox/creds/puppet-factsrole (svc-puppet-facts, 24h ttl / 72h max_ttl). Question: how should puppet hosts obtain their token?Investigation findings
hiera-vault/vaultlookup backend, not evenhiera-eyaml(hiera.yamlis plainyaml_data). The fact cannot fetchnetbox/creds/puppet-factsat runtime today.Design decision needed
api_tokena long-lived NetBox token created directly in NetBox forsvc-puppet-facts, seeded in hieradata. Do NOT mint it from the engine. No puppet change; engine used only for terraform-infra for now.netbox/creds/puppet-factsand re-seed hieradata on a <=72h cadence. Adds operational toil.netbox/creds/puppet-factseach run and never stores a long-lived token. Scope separately.Recommendation
Option 1 now (no puppet code change; the profile already accepts a hiera-seeded token), with Option 3 tracked as the real fix if puppet-host Vault auth is introduced. Flagging for a call before any code lands.