Igor2
@nblair2/igor2v2026.05.30.1
01README
Full igor2 cluster-manager control via the REST API, split into five models: reservations (the reservation lifecycle), hosts (power, inventory, administration, host policies), boot (distros, profiles, images, kickstarts), identity (users, groups, privilege elevation), and server (clusters/MOTD, sync, stats, config, auth-reset, dashboard).
02Models
@nblair2/igor2/reservationsv2026.05.30.1reservations.ts
fn reservation_create(name: string, nodeList?: string, nodeCount?: number, profile?: string, distro?: string, duration?: union, start?: number, group?: string, vlan?: string, kernelArgs?: string, description?: string, owner?: string, noCycle?: boolean)
Create a node reservation; idempotent (returns the existing one on conflict)
| Argument | Type | Description |
|---|---|---|
| name | string | Unique reservation name |
| nodeList? | string | Explicit nodes, e.g. 'kn1,kn3' or 'kn[1-5]' (mutually exclusive with nodeCount) |
| nodeCount? | number | Number of any available nodes to reserve (mutually exclusive with nodeList) |
| profile? | string | Boot profile name (provide profile OR distro) |
| distro? | string | Boot distro name (provide profile OR distro) |
| duration? | union | Length, e.g. '3d' or '5h30m', or a Unix-epoch end time |
| start? | number | Start time as a Unix-epoch timestamp |
| group? | string | Group to grant access to |
| vlan? | string | VLAN id, or the name of a reservation to share a VLAN with |
| kernelArgs? | string | Extra kernel arguments |
| description? | string | Free-text description |
| owner? | string | Owner username (admin only) |
| noCycle? | boolean | Skip the power cycle on install |
fn reservation_show(name: string)
Fetch a single reservation by name and store its state
| Argument | Type | Description |
|---|---|---|
| name | string | Reservation name |
fn reservation_list()
List all visible reservations, storing each one
fn reservation_edit(name: string, extend?: union, extendMax?: boolean, drop?: string, addNodeList?: string, addNodeCount?: number, distro?: string, profile?: string, newName?: string, owner?: string, group?: string, kernelArgs?: string, description?: string)
Modify a reservation (extend, add/drop nodes, rename, re-distro, etc.)
| Argument | Type | Description |
|---|---|---|
| name | string | Reservation to edit |
| extend? | union | Extend by a duration ('3d') or to a Unix-epoch end time |
| extendMax? | boolean | Extend to the maximum allowed |
| drop? | string | Nodes to remove, e.g. 'kn[1-3]' |
| addNodeList? | string | Nodes to add, e.g. 'kn[10-12]' |
| addNodeCount? | number | Number of additional nodes to add |
| distro? | string | Change boot distro |
| profile? | string | Change boot profile |
| newName? | string | Rename the reservation |
| owner? | string | Transfer ownership |
| group? | string | Change group ('none' to clear) |
| kernelArgs? | string | Update kernel arguments |
| description? | string | Update description |
fn reservation_delete(name: string)
Delete a reservation
| Argument | Type | Description |
|---|---|---|
| name | string | Reservation name |
Resources
reservation(infinite)— An igor2 node reservation and its current host state
@nblair2/igor2/hostsv2026.05.30.1hosts.ts
fn host_power(cmd: enum, hosts?: string, reservation?: string)
Power on/off/cycle nodes, or query their power status
| Argument | Type | Description |
|---|---|---|
| cmd | enum | Power command |
| hosts? | string | Host range, e.g. 'kn[1-5]' (mutually exclusive with reservation) |
| reservation? | string | Reservation whose nodes to target (mutually exclusive with hosts) |
fn host_list()
List all hosts, storing each one
fn host_status(name: string)
Fetch a single host by name and store its state
| Argument | Type | Description |
|---|---|---|
| name | string | Host name, e.g. 'kn1' |
fn host_edit(name: string, ip?: string, hostname?: string, boot?: enum, mac?: string, eth?: string, hostPolicy?: string)
Edit a host's network/boot attributes or its host policy (admin)
| Argument | Type | Description |
|---|---|---|
| name | string | Host name to edit, e.g. 'kn1' |
| ip? | string | New IP address |
| hostname? | string | New hostname |
| boot? | enum | Boot mode |
| mac? | string | New MAC address |
| eth? | string | Ethernet interface name |
| hostPolicy? | string | Host policy name ('' resets to the default policy) |
fn host_delete(name: string)
Delete a host from igor2 (admin)
| Argument | Type | Description |
|---|---|---|
| name | string | Resource name |
fn host_block(hosts: string, block: boolean)
Block or unblock hosts from being reserved (admin)
| Argument | Type | Description |
|---|---|---|
| hosts | string | Host range, e.g. 'kn[1-5]' |
| block | boolean | true to block, false to unblock |
fn host_apply_policy(nodeList: string, policy: string)
Apply a host policy to a set of hosts (admin)
| Argument | Type | Description |
|---|---|---|
| nodeList | string | Host range, e.g. 'kn[1-5]' |
| policy | string | Host policy name to apply |
fn hostpolicy_create(name: string, maxResTime?: string, accessGroups?: array, notAvailable?: array)
Create a host policy (admin)
| Argument | Type | Description |
|---|---|---|
| name | string | Host policy name |
| maxResTime? | string | Maximum reservation time as a duration, e.g. '24h' or '7d' |
| accessGroups? | array | Groups allowed to reserve hosts under this policy |
| notAvailable? | array | Cron-based unavailability blocks |
fn hostpolicy_list()
List all host policies, storing each one
fn hostpolicy_show(name: string)
Fetch a single host policy by name and store it
| Argument | Type | Description |
|---|---|---|
| name | string | Resource name |
fn hostpolicy_edit(name: string, newName?: string, maxResTime?: string, accessGroups?: array, notAvailable?: array)
Edit a host policy (admin)
| Argument | Type | Description |
|---|---|---|
| name | string | Host policy to edit |
| newName? | string | Rename the policy |
| maxResTime? | string | New maximum reservation time |
| accessGroups? | array | Replace access groups |
| notAvailable? | array | Replace unavailability blocks |
fn hostpolicy_delete(name: string)
Delete a host policy (admin)
| Argument | Type | Description |
|---|---|---|
| name | string | Resource name |
Resources
host(infinite)— An igor2 cluster host and its power/boot state
hostPolicy(infinite)— An igor2 host policy (max reservation time, access groups)
powerResult(7d)— Result of a host power command
operation(7d)— Outcome of a host block/unblock or apply-policy action
@nblair2/igor2/bootv2026.05.30.1boot.ts
fn distro_create(name: string, copyDistro?: string, useDistroImage?: string, imageRef?: string, kernelFile?: string, initrdFile?: string, description?: string, kernelArgs?: string, kickstart?: string, public?: boolean, distroGroups?: array, boot?: array)
Create a boot distro by copying a distro, reusing an image, referencing an image ID, or uploading kernel+initrd
| Argument | Type | Description |
|---|---|---|
| name | string | Unique distro name |
| copyDistro? | string | Create by copying an existing distro (one source required) |
| useDistroImage? | string | Create using the image of an existing distro (one source required) |
| imageRef? | string | Create from an already-registered image ID (one source required) |
| kernelFile? | string | Local path to a kernel file to upload (with initrdFile; one source required) |
| initrdFile? | string | Local path to an initrd file to upload (with kernelFile) |
| description? | string | Free-text description |
| kernelArgs? | string | Default kernel arguments |
| kickstart? | string | Kickstart filename (local-boot images only) |
| public? | boolean | Make the distro public (admin) |
| distroGroups? | array | Groups granted access (not allowed if public) |
| boot? | array | Supported boot modes |
fn distro_list()
List all visible distros, storing each one
fn distro_show(name: string)
Fetch a single distro by name and store it
| Argument | Type | Description |
|---|---|---|
| name | string | Resource name |
fn distro_edit(name: string, newName?: string, description?: string, kernelArgs?: string, owner?: string, addGroup?: array, removeGroup?: array, kickstart?: string, public?: boolean, setDefault?: boolean, removeDefault?: boolean)
Edit a distro (rename, groups, kernel args, default, etc.)
| Argument | Type | Description |
|---|---|---|
| name | string | Distro to edit |
| newName? | string | Rename the distro |
| description? | string | Update description |
| kernelArgs? | string | Update default kernel arguments |
| owner? | string | Transfer ownership (admin) |
| addGroup? | array | Groups to grant access |
| removeGroup? | array | Groups to revoke access |
| kickstart? | string | Update kickstart filename |
| public? | boolean | Make the distro public (admin) |
| setDefault? | boolean | Set as the default distro (admin) |
| removeDefault? | boolean | Clear default-distro status |
fn distro_delete(name: string)
Delete a distro
| Argument | Type | Description |
|---|---|---|
| name | string | Resource name |
fn profile_create(name: string, distro: string, description?: string, kernelArgs?: string)
Create a boot profile (a distro plus extra kernel arguments)
| Argument | Type | Description |
|---|---|---|
| name | string | Unique profile name |
| distro | string | Distro this profile boots |
| description? | string | Free-text description |
| kernelArgs? | string | Extra kernel arguments appended to the distro's |
fn profile_list()
List all visible profiles, storing each one
fn profile_show(name: string)
Fetch a single profile by name and store it
| Argument | Type | Description |
|---|---|---|
| name | string | Resource name |
fn profile_edit(name: string, newName?: string, description?: string, kernelArgs?: string)
Edit a profile (rename, description, kernel arguments)
| Argument | Type | Description |
|---|---|---|
| name | string | Profile to edit |
| newName? | string | Rename the profile |
| description? | string | Update description |
| kernelArgs? | string | Update kernel arguments |
fn profile_delete(name: string)
Delete a profile
| Argument | Type | Description |
|---|---|---|
| name | string | Resource name |
fn image_register(kernelFile?: string, initrdFile?: string, kstaged?: string, istaged?: string, breed?: string, localBoot?: boolean, boot?: array)
Register a distro image by uploading kernel+initrd files or referencing server-staged files
| Argument | Type | Description |
|---|---|---|
| kernelFile? | string | Local path to a kernel file to upload (with initrdFile) |
| initrdFile? | string | Local path to an initrd file to upload (with kernelFile) |
| kstaged? | string | Server-staged kernel filename (with istaged) instead of uploading |
| istaged? | string | Server-staged initrd filename (with kstaged) |
| breed? | string | Distro breed (e.g. ubuntu, redhat, generic-linux) |
| localBoot? | boolean | Register as a local-install image |
| boot? | array | Supported boot modes |
fn image_list()
List all registered distro images, storing each one
fn image_delete(name: string)
Delete a registered distro image by name/ID
| Argument | Type | Description |
|---|---|---|
| name | string | Resource name |
fn kickstart_register(kickstart: string)
Register (upload) a kickstart file
| Argument | Type | Description |
|---|---|---|
| kickstart | string | Local path to a kickstart file to upload |
fn kickstart_list()
List all kickstart files, storing each one
fn kickstart_edit(name: string, kickstart?: string, newName?: string)
Replace a kickstart's file and/or rename it
| Argument | Type | Description |
|---|---|---|
| name | string | Kickstart to edit |
| kickstart? | string | Local path to a replacement kickstart file |
| newName? | string | Rename the kickstart |
fn kickstart_delete(name: string)
Delete a kickstart file
| Argument | Type | Description |
|---|---|---|
| name | string | Resource name |
Resources
distro(infinite)— An igor2 boot distro (kernel/initrd + kickstart + groups)
profile(infinite)— An igor2 boot profile (a distro plus kernel arguments)
image(infinite)— A registered igor2 distro image (kernel/initrd pair)
kickstart(infinite)— A registered igor2 kickstart file
@nblair2/igor2/identityv2026.05.30.1identity.ts
fn user_create(name: string, email: string)
Create a user account (admin)
| Argument | Type | Description |
|---|---|---|
| name | string | Username |
| string | Email address |
fn user_list()
List users, storing each one
fn user_show(name: string)
Fetch a single user by name and store it
| Argument | Type | Description |
|---|---|---|
| name | string | Resource name |
fn user_edit(name: string, email?: string, fullName?: string, password?: string, oldPassword?: string, reset?: boolean)
Edit a user: email/fullName, change password, or force a reset
| Argument | Type | Description |
|---|---|---|
| name | string | User to edit |
| email? | string | New email address |
| fullName? | string | New full name |
| password? | string | New password (requires oldPassword) |
| oldPassword? | string | Current password (required when changing password) |
| reset? | boolean | Force a password reset (cannot combine with other edits) |
fn user_delete(name: string)
Delete a user account (admin)
| Argument | Type | Description |
|---|---|---|
| name | string | Resource name |
fn group_create(name: string, isLDAP?: boolean, members?: array, owners?: array, description?: string)
Create a group (optionally LDAP-backed)
| Argument | Type | Description |
|---|---|---|
| name | string | Group name |
| isLDAP? | boolean | Back the group with LDAP (no members/owners/description allowed) |
| members? | array | Member usernames |
| owners? | array | Owner usernames |
| description? | string | Free-text description |
fn group_list(showMembers?: boolean)
List groups (owned and member), storing each one
| Argument | Type | Description |
|---|---|---|
| showMembers? | boolean | Include member lists |
fn group_show(name: string)
Fetch a single group by name and store it
| Argument | Type | Description |
|---|---|---|
| name | string | Resource name |
fn group_edit(name: string, newName?: string, description?: string, addOwners?: array, rmvOwners?: array, add?: array, remove?: array)
Edit a group: metadata, owners, or members (one facet)
| Argument | Type | Description |
|---|---|---|
| name | string | Group to edit |
| newName? | string | Rename the group |
| description? | string | Update description |
| addOwners? | array | Owners to add |
| rmvOwners? | array | Owners to remove |
| add? | array | Members to add |
| remove? | array | Members to remove |
fn group_delete(name: string)
Delete a group (admin)
| Argument | Type | Description |
|---|---|---|
| name | string | Resource name |
fn elevate()
Activate admin privilege elevation for your session
fn elevate_status()
Check remaining time on your admin elevation
fn elevate_cancel()
Cancel your admin privilege elevation
Resources
user(infinite)— An igor2 user account
group(infinite)— An igor2 group (owners, members, shared distros/policies)
operation(7d)— Outcome of an elevate / elevate-status / elevate-cancel action
@nblair2/igor2/serverv2026.05.30.1server.ts
fn cluster_list()
List clusters, storing each one
fn cluster_motd_set(motd: string, motdUrgent: boolean)
Set the cluster message-of-the-day (admin)
| Argument | Type | Description |
|---|---|---|
| motd | string | Message-of-the-day text ('' to clear) |
| motdUrgent | boolean | Flag the MOTD as urgent |
fn sync(cmd: string, force?: boolean, quiet?: boolean, scope?: string)
Run a network sync check (e.g. Arista VLAN reconciliation)
| Argument | Type | Description |
|---|---|---|
| cmd | string | Sync command (currently only 'arista') |
| force? | boolean | Apply corrections on mismatch |
| quiet? | boolean | Suppress detailed output |
| scope? | string | Limit to a host range or reservation names |
fn stats(start?: string, duration?: number, verbose?: boolean)
Read cluster usage statistics and store the snapshot
| Argument | Type | Description |
|---|---|---|
| start? | string | End of the range as 'YYYY-Mon-DD' (e.g. 2026-May-28) |
| duration? | number | Days back from start (default 7; 0 = since epoch) |
| verbose? | boolean | Include per-reservation entries |
fn config_show(public?: boolean)
Read the igor2 server configuration (or public settings)
| Argument | Type | Description |
|---|---|---|
| public? | boolean | Read only the public settings (no admin required) |
fn auth_reset(confirm: literal)
Reset the server JWT signing secret — DESTRUCTIVE: invalidates every issued token cluster-wide (admin)
| Argument | Type | Description |
|---|---|---|
| confirm | literal | Must be true — this invalidates ALL issued JWT tokens cluster-wide |
fn show(public?: boolean)
Read the cluster dashboard (cluster meta, hosts, reservations)
| Argument | Type | Description |
|---|---|---|
| public? | boolean | Read only the public settings (no admin required) |
Resources
cluster(infinite)— An igor2 cluster definition and its MOTD
dashboard(7d)— Cluster dashboard snapshot (cluster meta, hosts, reservations)
stats(7d)— An igor2 cluster usage-statistics snapshot
config(7d)— The igor2 server configuration snapshot
operation(7d)— Outcome of a sync, MOTD-set or auth-reset action
03Previous Versions
2026.05.28.2May 29, 2026
04Stats
A
100 / 100
Downloads
0
Archive size
58.0 KB
- Has README or module doc2/2earned
- README has a code example1/1earned
- README is substantive1/1earned
- Most symbols documented1/1earned
- No slow types1/1earned
- Dependencies pass trust audit2/2earned
- Has description1/1earned
- Platform support declared (or universal)2/2earned
- License declared1/1earned
- Verified public repository2/2earned
Repository
https://github.com/nblair2/swamp-igor205Platforms
06Labels