Added headscale login

This commit is contained in:
Hannes
2026-04-18 01:08:23 +02:00
parent efec41b290
commit f02c1e1b31
2 changed files with 39 additions and 0 deletions
+34
View File
@@ -0,0 +1,34 @@
# headscale server
## Docker (Truenas Scale App)
### user
You need to be have at least one user. You can think of a user as one local network.
```
sudo docker exec ix-headscale-headscale-1 headscale users create <user>
```
List the users:
```
sudo docker exec ix-headscale-headscale-1 headscale users list
```
Add a key to a user:
```
sudo docker exec ix-headscale-headscale-1 headscale nodes register --user <user> --key <key>
```
### nodes/devices
The nodes are the devices registered to a user/network.
List the nodes:
```
sudo docker exec ix-headscale-headscale-1 headscale nodes list
```
### Creating key
Normaly you just let the Truenas Client create the key for you.
But if you want to run the docker app to add a device to a tailscale/headscale instance you need to manually create a key.
```
sudo docker exec ix-headscale-headscale-1 headscale preauthkeys create --user <user/uid> --reusable=false
sudo docker exec ix-headscale-headscale-1 headscale preauthkeys create --user <user/uid> --reusable=true
```
You get the ID from listing all the Users.
+5
View File
@@ -0,0 +1,5 @@
# Adding a client to headscale
## headscale
```
sudo tailscale up --login-server <domain>
```