|
|
@ -37,6 +37,9 @@ unlink(</var/lib/pydio/tmp/sess_*>); |
|
|
|
# Remove plugin cache |
|
|
|
# Remove plugin cache |
|
|
|
unlink(</var/cache/pydio/plugin*.ser>); |
|
|
|
unlink(</var/cache/pydio/plugin*.ser>); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
my $pydio = $c->get('pydio') || die "Couldn't find pydio entry in ConfigDB\n"; |
|
|
|
|
|
|
|
my $homedir = $pydio->prop('HomeDir') || 'none'; |
|
|
|
|
|
|
|
|
|
|
|
foreach my $user (($a->users),$a->get('admin')){ |
|
|
|
foreach my $user (($a->users),$a->get('admin')){ |
|
|
|
my $name = $user->key; |
|
|
|
my $name = $user->key; |
|
|
|
my $first = $user->prop('FirstName') || ''; |
|
|
|
my $first = $user->prop('FirstName') || ''; |
|
|
@ -86,6 +89,10 @@ foreach my $user (($a->users),$a->get('admin')){ |
|
|
|
# Special case: admin has access to everything |
|
|
|
# Special case: admin has access to everything |
|
|
|
$data->{"\0*\0acls"}->{$sharename} = 'rw' if ($name eq 'admin'); |
|
|
|
$data->{"\0*\0acls"}->{$sharename} = 'rw' if ($name eq 'admin'); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
# Set ACL for the private homedir if enabled |
|
|
|
|
|
|
|
if ($homedir eq 'enabled' || ($homedir eq 'users' && (($user->prop('PydioHomeDir') || 'disabled') eq 'enabled'))){ |
|
|
|
|
|
|
|
$data->{"\0*\0acls"}->{'home'} = 'r'; |
|
|
|
|
|
|
|
} |
|
|
|
# As we're here, lets update the email address and the display name |
|
|
|
# As we're here, lets update the email address and the display name |
|
|
|
# First, delete parameter if it's an array (meaning it's empty) |
|
|
|
# First, delete parameter if it's an array (meaning it's empty) |
|
|
|
delete $data->{"\0*\0parameters"} if (ref ($data->{"\0*\0parameters"})=~ m/ARRAY/i); |
|
|
|
delete $data->{"\0*\0parameters"} if (ref ($data->{"\0*\0parameters"})=~ m/ARRAY/i); |
|
|
@ -101,9 +108,6 @@ foreach my $user (($a->users),$a->get('admin')){ |
|
|
|
chown '0', '102', "/var/lib/pydio/plugins/auth.serial/$name/role.ser"; |
|
|
|
chown '0', '102', "/var/lib/pydio/plugins/auth.serial/$name/role.ser"; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
my $pydio = $c->get('pydio') || die "Couldn't find pydio entry in ConfigDB\n"; |
|
|
|
|
|
|
|
my $homedir = $pydio->prop('HomeDir') || 'none'; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if ($homedir eq 'enabled'){ |
|
|
|
if ($homedir eq 'enabled'){ |
|
|
|
foreach ($a->users){ |
|
|
|
foreach ($a->users){ |
|
|
|
my $name = $_->key; |
|
|
|
my $name = $_->key; |
|
|
|