smeserver-samba/root/etc/e-smith/db/configuration/migrate/30smbServerName

10 lines
313 B
Plaintext

{
# Set ServerName to SystemName after inital configuration.
my $smb = $DB->get('smb') || return;
my $srvName = $smb->prop('ServerName') || 'sme-server';
my $sysName = $DB->get('SystemName') || return;
return unless $srvName =~ m#sme-server#;
$smb->set_prop('ServerName', $sysName->value);
}