Default change group if not found
This commit is contained in:
parent
19d4d3220c
commit
abb0d51de9
|
@ -612,6 +612,7 @@ sub set_file_permissions($$;$) {
|
||||||
my $uid = getpwnam($pa_config->{'user'});
|
my $uid = getpwnam($pa_config->{'user'});
|
||||||
my $gid = getgrnam($pa_config->{'group'});
|
my $gid = getgrnam($pa_config->{'group'});
|
||||||
my $perm = $grants & (~oct($pa_config->{'umask'}));
|
my $perm = $grants & (~oct($pa_config->{'umask'}));
|
||||||
|
$gid = getgrnam("www-data") if (!defined($gid));
|
||||||
|
|
||||||
chown $uid, $gid, $file;
|
chown $uid, $gid, $file;
|
||||||
chmod ( $perm, $file );
|
chmod ( $perm, $file );
|
||||||
|
|
Loading…
Reference in New Issue