Generate unique givennames for hosts joining (and debug added)
This commit is contained in:
parent
03cccd60a6
commit
5fa3016703
2 changed files with 8 additions and 6 deletions
|
@ -394,9 +394,15 @@ func (api headscaleV1APIServer) DebugCreateMachine(
|
|||
Hostname: "DebugTestMachine",
|
||||
}
|
||||
|
||||
givenName, err := api.h.GenerateGivenName(request.GetName())
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
newMachine := Machine{
|
||||
MachineKey: request.GetKey(),
|
||||
Hostname: request.GetName(),
|
||||
GivenName: givenName,
|
||||
Namespace: *namespace,
|
||||
|
||||
Expiry: &time.Time{},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue