← 返回命令列表

Linux command

tailscale-set 命令

文件

复制后可按需替换文件名、目录或参数。

常用示例

Accept routes

tailscale set --accept-routes

Advertise this device as an exit node

tailscale set --advertise-exit-node

Set the device hostname

tailscale set --hostname [name]

Allow a non-root user to control tailscaled

tailscale set --operator=[$USER]

Route this device's traffic through an exit node

tailscale set --exit-node [node-name-or-ip]

说明

tailscale set changes per-node Tailscale options without disrupting the existing connection. Unlike tailscale up, which resets every unspecified flag back to its default, set modifies only the flags you pass — making it the safer choice for incremental changes.

参数

--accept-routes
Accept subnet routes advertised by other nodes.
--accept-dns
Accept DNS configuration from the admin console.
--advertise-routes _CIDRS_
Expose physical subnet routes to the tailnet.
--advertise-exit-node
Offer this node as an exit node.
--advertise-tags _TAGS_
Apply ACL tags to this device.
--exit-node _NODE_
Route traffic through the named exit node (empty string clears it).
--exit-node-allow-lan-access
Allow LAN access while connected to an exit node.
--hostname _NAME_
Override the device hostname.
--shields-up
Block all incoming connections.
--ssh
Enable Tailscale SSH on this device.
--operator _USER_
Allow the named local user to operate tailscaled without sudo.
--auto-update
Enable automatic Tailscale client updates (where supported).

FAQ

What is the tailscale-set command used for?

tailscale set changes per-node Tailscale options without disrupting the existing connection. Unlike tailscale up, which resets every unspecified flag back to its default, set modifies only the flags you pass — making it the safer choice for incremental changes.

How do I run a basic tailscale-set example?

Run `tailscale set --accept-routes` in a terminal, then adjust file names, paths, flags, or remote targets for your system.

What does --accept-routes do in tailscale-set?

Accept subnet routes advertised by other nodes.