mirror of
git://git.proxmox.com/git/pve-storage.git
synced 2025-03-11 16:58:28 +03:00
ovf import: guest name: normalize whitespace to minus
This is nicer from a readability POV, but replace a arbitrary amount of whitespace by a single minus character to avoid making it look odd. Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
parent
628bd29082
commit
af83df01a8
@ -209,6 +209,7 @@ sub parse_ovf {
|
||||
|
||||
if ($ovf_name) {
|
||||
# PVE::QemuServer::confdesc requires a valid DNS name
|
||||
$ovf_name =~ s/\s+/-/g;
|
||||
($qm->{name} = $ovf_name) =~ s/[^a-zA-Z0-9\-\.]//g;
|
||||
} else {
|
||||
warn "warning: unable to parse the VM name in this OVF manifest, generating a default value\n";
|
||||
|
Loading…
x
Reference in New Issue
Block a user