Commit Graph

3 Commits

Author SHA1 Message Date
unkin-agent 380fcff20c Create NetBox sites rather than requiring them to pre-exist
ci/woodpecker/pr/plan Pipeline was successful
ci/woodpecker/pr/pre-commit Pipeline was successful
The syd1 site does not exist, so the site data source failed the plan.
Sites now follow the same declared-by-reference rule as device roles,
types and manufacturers.
2026-10-03 15:41:38 +10:00
unkin-agent 4c9bfb0448 Read the minted NetBox credential from the engine's token field
ci/woodpecker/pr/pre-commit Pipeline was successful
ci/woodpecker/pr/plan Pipeline failed
The engine returns it as "token"; "netbox_token" does not exist, so the
plan failed with Invalid index before reaching NetBox.
2026-10-03 15:40:11 +10:00
unkin-agent d7c05b00ac Initial terraform-netbox: NetBox prefixes, devices, platforms, custom fields
ci/woodpecker/pr/plan Pipeline failed
ci/woodpecker/pr/pre-commit Pipeline was successful
Carried over from terraform-infra, scoped to NetBox: Kea is managed by the
kea-operator CRs. Devices carried no platform and NetBox had no custom
fields, so bootapi could only ever render its default template.

- prefixes, DHCP-pool ip_ranges, gateways, networks, devices and the
  PuppetDB backfill script, minus every Kea resource, provider and token
- netbox_custom_field definitions from config/<region>/<dc>/custom-fields.yaml
- netbox_platform per declared platform, set as the device platform_id
- model_hint written to the device provision_template custom field
- state key infra/terraform/netbox, NetBox token from netbox/creds/terraform-netbox

pxe_enabled's value is deliberately unmanaged: it is runtime state that
bootapi's provisioned callback clears.
2026-10-03 15:38:02 +10:00