Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Ian Eiloart
Sympl
Commits
b310e02b
Commit
b310e02b
authored
Jul 09, 2019
by
Paul Cammish
Browse files
Don't drop permissions, reload apache.
parent
614f92d0
Changes
1
Hide whitespace changes
Inline
Side-by-side
web/sbin/sympl-web-rotate-logs
View file @
b310e02b
...
...
@@ -227,14 +227,6 @@ Symbiosis::Domains.each(prefix) do |domain|
#
rotated
=
true
#
# Drop privileges
#
if
0
==
Process
.
uid
Process
::
Sys
.
setegid
(
domain
.
gid
)
Process
::
Sys
.
seteuid
(
domain
.
uid
)
end
#
# Process these files backward so we don't over-write anything.
#
...
...
@@ -273,13 +265,6 @@ Symbiosis::Domains.each(prefix) do |domain|
end
end
#
# Restore back to root.
#
if
0
==
Process
.
uid
Process
::
Sys
.
seteuid
(
0
)
Process
::
Sys
.
setegid
(
0
)
end
end
#
...
...
@@ -290,8 +275,8 @@ if ( rotated )
# TODO: Really we want to send HUP to those processes which have the
# logfiles we've rotated open, rather than blindly stabbing things.
#
verbose
(
"Since we rotated we now re
start the httpd logger
"
)
Kernel
.
system
(
"
killall -HUP sympl-web-logger
"
)
verbose
(
"Since we rotated we now re
load Apache
"
)
Kernel
.
system
(
"
/usr/sbin/service apache2 reload
"
)
#
# Add similar arguments on to the generate-stats command as wot we received.
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment