diff --git a/pkg/compute/models/guests.go b/pkg/compute/models/guests.go index 7645b51e12..d4da072fb6 100644 --- a/pkg/compute/models/guests.go +++ b/pkg/compute/models/guests.go @@ -6758,7 +6758,7 @@ var ( ) func (manager *SGuestManager) ValidateNameLoginAccount(name string) error { - if hostnameREG.MatchString(name) { + if serverNameREG.MatchString(name) { return nil } return httperrors.NewInputParameterError("name starts with letter, and contains letter, number and - only")