Skip to main content

Update

Set the hostname on the target node:

$ osapi client node hostname update --name web-01

Job ID: 550e8400-e29b-41d4-a716-446655440000

STATUS CHANGED ERROR
ok true

When the target host does not support the operation:

$ osapi client node hostname update --name web-01 --target darwin-host

Job ID: 550e8400-e29b-41d4-a716-446655440000

STATUS CHANGED ERROR
skipped host: operation not supported on this OS family

When targeting all hosts:

$ osapi client node hostname update --name web-01 --target _all

Job ID: 550e8400-e29b-41d4-a716-446655440000

HOSTNAME STATUS CHANGED ERROR
server1 ok true
server2 skipped unsupported platform

Flags

FlagDescriptionDefault
--nameNew hostname to set (required)required
-T, --targetTarget: _any, _all, hostname, or label (group:web)_any