Skip to main content
Version: v5.6.1

opschain infrastructure bulk-upsert

packs:infrastructure

Registers or updates a batch of infrastructure nodes under one parent in one set-based write — the lane sync jobs use, since inventories arrive in batches. Items whose code is new are created; existing codes are updated in place. A per-item validation failure lands in that item's result without failing the batch; the server's batch cap refuses a larger batch by name.

The batch file is YAML:

items:
- code: kvm01
name: KVM Host 1
type: host
address: 10.1.1.1
fqdn: kvm01.prod.example
properties:
os_family: linux
- code: sw01
name: Core Switch
type: network_device
opschain infrastructure bulk-upsert --parent /projects/web/environments/prod --file inventory.yaml
Created: 2 Updated: 0 Failed: 0

-o, --output json|yaml emits per-item outcomes and warnings as a machine document.

Flags​

FlagMeaning
--parent <node-path>Parent node path (required): a project, environment or asset.
--file <path>YAML batch file (required).
--server <url>Server base URL (default: the active context / OPSCHAIN_SERVER).
--auth-token <token>Admin bearer token override (default: your opschain login session, then $OPSCHAIN_ADMIN_TOKEN, then the token stored by opschain admin login).