Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Register
Sign in
Toggle navigation
Menu
Open sidebar
ISPConfig
ISPConfig 3
Commits
c8679f3e
Commit
c8679f3e
authored
Nov 14, 2015
by
Florian Schaal
Browse files
FS#4031 - Disabling server option "Network Filesystem" does not work
parent
576d93bb
Changes
2
Hide whitespace changes
Inline
Side-by-side
server/plugins-available/apache2_plugin.inc.php
View file @
c8679f3e
...
...
@@ -595,7 +595,7 @@ class apache2_plugin {
//* Unmount the old log directory bfore we move the log dir
//exec('fuser -km '.escapeshellcmd($old_dir.'/log'));
exec
(
'umount '
.
escapeshellcmd
(
$
old_dir
.
'/log'
));
exec
(
'umount '
.
escapeshellcmd
(
$
data
[
'old'
][
'document_root'
]
.
'/log'
));
//* Create new base directory, if it does not exist yet
if
(
!
is_dir
(
$new_dir
))
$app
->
system
->
mkdirpath
(
$new_dir
);
...
...
@@ -691,7 +691,8 @@ class apache2_plugin {
$app
->
system
->
chmod
(
$data
[
'new'
][
'document_root'
]
.
'/'
.
$log_folder
,
0755
);
exec
(
'mount --bind '
.
escapeshellarg
(
'/var/log/ispconfig/httpd/'
.
$data
[
'new'
][
'domain'
])
.
' '
.
escapeshellarg
(
$data
[
'new'
][
'document_root'
]
.
'/'
.
$log_folder
));
//* add mountpoint to fstab
$fstab_line
=
'/var/log/ispconfig/httpd/'
.
$data
[
'new'
][
'domain'
]
.
' '
.
$data
[
'new'
][
'document_root'
]
.
'/'
.
$log_folder
.
' none bind,nobootwait,_netdev 0 0'
;
$fstab_line
=
'/var/log/ispconfig/httpd/'
.
$data
[
'new'
][
'domain'
]
.
' '
.
$data
[
'new'
][
'document_root'
]
.
'/'
.
$log_folder
.
' none bind,nobootwait'
;
$fstab_line
.
=
@
(
$web_config
[
'network_filesystem'
]
==
'y'
)
?
',_netdev 0 0'
:
' 0 0'
;
$app
->
system
->
replaceLine
(
'/etc/fstab'
,
$fstab_line
,
$fstab_line
,
1
,
1
);
}
...
...
server/plugins-available/nginx_plugin.inc.php
View file @
c8679f3e
...
...
@@ -476,7 +476,7 @@ class nginx_plugin {
//* Unmount the old log directory bfore we move the log dir
//exec('fuser -km '.escapeshellcmd($old_dir.'/log'));
exec
(
'umount '
.
escapeshellcmd
(
$
old_dir
.
'/log'
));
exec
(
'umount '
.
escapeshellcmd
(
$
data
[
'old'
][
'document_root'
]
.
'/log'
));
//* Create new base directory, if it does not exist yet
if
(
!
is_dir
(
$new_dir
))
$app
->
system
->
mkdirpath
(
$new_dir
);
...
...
@@ -572,7 +572,8 @@ class nginx_plugin {
$app
->
system
->
chmod
(
$data
[
'new'
][
'document_root'
]
.
'/'
.
$log_folder
,
0755
);
exec
(
'mount --bind '
.
escapeshellarg
(
'/var/log/ispconfig/httpd/'
.
$data
[
'new'
][
'domain'
])
.
' '
.
escapeshellarg
(
$data
[
'new'
][
'document_root'
]
.
'/'
.
$log_folder
));
//* add mountpoint to fstab
$fstab_line
=
'/var/log/ispconfig/httpd/'
.
$data
[
'new'
][
'domain'
]
.
' '
.
$data
[
'new'
][
'document_root'
]
.
'/'
.
$log_folder
.
' none bind,nobootwait,_netdev 0 0'
;
$fstab_line
=
'/var/log/ispconfig/httpd/'
.
$data
[
'new'
][
'domain'
]
.
' '
.
$data
[
'new'
][
'document_root'
]
.
'/'
.
$log_folder
.
' none bind,nobootwait'
;
$fstab_line
.
=
@
(
$web_config
[
'network_filesystem'
]
==
'y'
)
?
',_netdev 0 0'
:
' 0 0'
;
$app
->
system
->
replaceLine
(
'/etc/fstab'
,
$fstab_line
,
$fstab_line
,
1
,
1
);
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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