Skip to content

Commit 3a18fe7

Browse files
author
Till Brehm
committed
Merge branch '6569-apache2-fcgid.conf' into 'develop'
apache2 fcgid.conf should place new argument inside IfModule Closes #6569 See merge request ispconfig/ispconfig3!1799
2 parents 93d7269 + 261f896 commit 3a18fe7

File tree

2 files changed

+5
-9
lines changed

2 files changed

+5
-9
lines changed

install/dist/lib/debian60.lib.php

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -209,14 +209,6 @@ public function configure_dovecot()
209209

210210
}
211211

212-
public function configure_apache() {
213-
global $conf;
214-
215-
if(file_exists('/etc/apache2/mods-available/fcgid.conf')) replaceLine('/etc/apache2/mods-available/fcgid.conf', 'MaxRequestLen', 'MaxRequestLen 15728640', 0, 1);
216-
217-
parent::configure_apache();
218-
}
219-
220212
public function configure_fail2ban() {
221213
/*
222214
copy('tpl/dovecot-pop3imap.conf.master',"/etc/fail2ban/filter.d/dovecot-pop3imap.conf");

install/lib/installer_base.lib.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2402,7 +2402,11 @@ public function configure_apache() {
24022402

24032403
if(is_file('/etc/apache2/mods-available/fcgid.conf')) {
24042404
// add or modify the parameters for fcgid.conf
2405-
replaceLine('/etc/apache2/mods-available/fcgid.conf','MaxRequestLen','MaxRequestLen 15728640',1);
2405+
if(hasLine('/etc/apache2/mods-available/fcgid.conf','MaxRequestLen')) {
2406+
replaceLine('/etc/apache2/mods-available/fcgid.conf','MaxRequestLen',' MaxRequestLen 15728640',1);
2407+
} else {
2408+
preg_replace('/^(.*\n)(.*)$/sU', '$1 MaxRequestLen 15728640\n$2', '/etc/apache2/mods-available/fcgid.conf');
2409+
}
24062410
}
24072411

24082412
if(is_file('/etc/apache2/apache.conf')) {

0 commit comments

Comments
 (0)