Make lemonldap-ng-cli work on RHEL systems (#649)
This commit is contained in:
parent
77492c0116
commit
4adba0b982
|
@ -8,7 +8,7 @@ sub giveUpPrivileges {
|
|||
my ( $user, $group ) = @_;
|
||||
|
||||
$user = "nobody" unless defined($user);
|
||||
$group = "nobody" unless defined($user);
|
||||
$group = "nobody" unless defined($group);
|
||||
|
||||
# become $user:$group and give up root privileges
|
||||
setgid( ( getgrnam($group) )[2] );
|
||||
|
@ -33,7 +33,7 @@ if ( !@ARGV ) {
|
|||
exit 1;
|
||||
}
|
||||
|
||||
giveUpPrivileges( "www-data", "www-data" );
|
||||
giveUpPrivileges( "__APACHEUSER__", "__APACHEGROUP__" );
|
||||
|
||||
my ( $cli, $action, $method, $ret );
|
||||
|
||||
|
|
|
@ -344,6 +344,7 @@ find %{buildroot} -name *.bak -exec rm -f {} \;
|
|||
# built as root
|
||||
sed -i 's/nobody/%{lm_apacheuser}/' %{buildroot}%{_sysconfdir}/cron.d/*
|
||||
sed -i 's/nobody/%{lm_apacheuser}/' %{buildroot}%{lm_sharedir}/bin/lmConfigEditor
|
||||
sed -i 's/nobody/%{lm_apacheuser}/' %{buildroot}%{lm_sharedir}/bin/lemonldap-ng-cli
|
||||
|
||||
# Minify Javascript and CSS
|
||||
./scripts/minifierjs `find %{buildroot} -name '*.js'`
|
||||
|
|
Loading…
Reference in New Issue
Block a user