Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
ISPConfig
ISPConfig Autoinstaller
Commits
4cd75e5e
Commit
4cd75e5e
authored
Feb 22, 2021
by
Thom Pol
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use php-fpm instead of mod_php, enable http2 (
#11
and
#28
)
parent
c680ace0
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
2 deletions
+20
-2
lib/os/class.ISPConfigDebianOS.inc.php
lib/os/class.ISPConfigDebianOS.inc.php
+20
-2
No files found.
lib/os/class.ISPConfigDebianOS.inc.php
View file @
4cd75e5e
...
...
@@ -158,7 +158,7 @@ class ISPConfigDebianOS extends ISPConfigBaseOS {
}
protected
function
getApacheModulesToEnable
()
{
$modules
=
array
(
'suexec'
,
'rewrite'
,
'ssl'
,
'actions'
,
'include'
,
'dav_fs'
,
'dav'
,
'auth_digest'
,
'cgi'
,
'headers'
,
'proxy_fcgi'
,
'alias'
);
$modules
=
array
(
'suexec'
,
'rewrite'
,
'ssl'
,
'actions'
,
'include'
,
'dav_fs'
,
'dav'
,
'auth_digest'
,
'cgi'
,
'headers'
,
'proxy_fcgi'
,
'alias'
,
'http2'
,
'mpm_event'
);
return
$modules
;
}
...
...
@@ -774,7 +774,6 @@ mailman-unsubscribe: "|/var/lib/mailman/mail/mailman unsubscribe mailman"';
'apache2-utils'
,
'libapache2-mod-fcgid'
,
'apache2-suexec-pristine'
,
'libapache2-mod-php'
,
'libapache2-mod-python'
,
'libapache2-mod-passenger'
);
...
...
@@ -852,6 +851,15 @@ mailman-unsubscribe: "|/var/lib/mailman/mail/mailman unsubscribe mailman"';
$this
->
installPackages
(
$packages
);
if
(
ISPConfig
::
shallInstall
(
'web'
)
&&
ISPConfig
::
$WEBSERVER
===
ISPC_WEBSERVER_APACHE
)
{
// Disable mpm_prefork so mpm_event can be used with http2
ISPConfigLog
::
info
(
'Disabling mpm_prefork module.'
,
true
);
$modules
=
'mpm_prefork'
;
$cmd
=
'a2dismod '
.
$modules
.
' 2>&1'
;
$result
=
$this
->
exec
(
$cmd
);
if
(
$result
===
false
)
{
throw
new
ISPConfigOSException
(
'Command '
.
$cmd
.
' failed.'
);
}
ISPConfigLog
::
info
(
'Enabling apache modules.'
,
true
);
$modules
=
$this
->
getApacheModulesToEnable
();
$cmd
=
'a2enmod '
.
implode
(
' '
,
$modules
)
.
' 2>&1'
;
...
...
@@ -859,6 +867,16 @@ mailman-unsubscribe: "|/var/lib/mailman/mail/mailman unsubscribe mailman"';
if
(
$result
===
false
)
{
throw
new
ISPConfigOSException
(
'Command '
.
$cmd
.
' failed.'
);
}
ISPConfigLog
::
info
(
'Enabling default PHP-FPM config.'
,
true
);
$conf
=
'php'
.
$this
->
getSystemPHPVersion
()
.
'-fpm'
;
$cmd
=
'a2enconf '
.
$conf
.
' 2>&1'
;
$result
=
$this
->
exec
(
$cmd
);
if
(
$result
===
false
)
{
throw
new
ISPConfigOSException
(
'Command '
.
$cmd
.
' failed.'
);
}
$this
->
restartService
(
'apache2'
);
}
try
{
...
...
Write
Preview
Markdown
is supported
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