initial commit of file from CVS for smeserver-phppgadmin on Sat Sep 7 20:53:08 AEST 2024
This commit is contained in:
11
root/etc/e-smith/db/configuration/migrate/phppgadmin
Normal file
11
root/etc/e-smith/db/configuration/migrate/phppgadmin
Normal file
@@ -0,0 +1,11 @@
|
||||
{
|
||||
my $rec = $DB->get('phppgadmin')
|
||||
|| $DB->new_record('phppgadmin', {type => 'configuration'});
|
||||
my $pw = $rec->prop('Password');
|
||||
if (not $pw or length($pw) < 20){
|
||||
my $pw = `/usr/bin/openssl rand -base64 28 | tr -c -d '[:alnum:]'`;
|
||||
$rec->set_prop('Password', $pw);
|
||||
}
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user