Usage
Arguments
Name or ID of the machine to update.
Flags
New name for the machine.
Public IP address of the machine for ingress configuration.
- IP address - Set a specific public IP
noneor blank - Remove the public IP
WireGuard endpoint address in format:
IP, IP:PORT, IPv6, or [IPv6]:PORT.Default port 51820 is used if omitted. Other machines in the cluster will use these endpoints to establish a WireGuard connection to this machine.Multiple endpoints can be specified by repeating the flag or using a comma-separated list.Examples
Rename a machine
Set the public IP address
Remove the public IP address
Useful for converting a machine to internal-only:Update WireGuard endpoints
Specify one or more endpoints:Update multiple properties at once
Output
The command shows what changed:Use Cases
Renaming Machines
Give machines descriptive names that reflect their role:Updating Public IPs
Update the public IP when your server’s IP changes:Managing WireGuard Endpoints
Update endpoints when:- Server gets a new public IP
- Network configuration changes
- Adding multiple network interfaces
- Switching between public and private networks
Important Notes
At Least One Flag Required
You must specify at least one flag to update. Running the command without flags will result in an error:WireGuard Endpoint Changes
When you update endpoints, other machines in the cluster will use the new endpoints to connect. Make sure the endpoints are reachable from other machines.Public IP and DNS
If you update the public IP of a machine running Caddy, you may need to update DNS records. Runuc caddy deploy to update DNS automatically.
Related Commands
uc machine ls- List machines and see current configurationuc machine add- Add a new machineuc machine rm- Remove a machine
