Skip to content
Snippets Groups Projects
Commit 07ce955c authored by Florian Schaal's avatar Florian Schaal
Browse files

Merge branch 'stable-3.1' of http://git.ispconfig.org/ispconfig/ispconfig3 into stable-3.1

parents a5c95e38 0064d598
No related branches found
No related tags found
1 merge request!554udate lng-files: "Send outgoing copy to" is used in sender_bcc_maps
...@@ -86,6 +86,8 @@ class page_action extends tform_actions { ...@@ -86,6 +86,8 @@ class page_action extends tform_actions {
function onSubmit() { function onSubmit() {
global $app, $conf; global $app, $conf;
if(substr($this->dataRecord['source'], 0, 1) === '@') $this->dataRecord['source'] = substr($this->dataRecord['source'], 1);
// Check the client limits, if user is not the admin // Check the client limits, if user is not the admin
if($_SESSION["s"]["user"]["typ"] != 'admin') { // if user is not admin if($_SESSION["s"]["user"]["typ"] != 'admin') { // if user is not admin
// Get the limits of the client // Get the limits of the client
......
...@@ -85,6 +85,8 @@ class page_action extends tform_actions { ...@@ -85,6 +85,8 @@ class page_action extends tform_actions {
function onSubmit() { function onSubmit() {
global $app, $conf; global $app, $conf;
if(substr($this->dataRecord['source'], 0, 1) === '@') $this->dataRecord['source'] = substr($this->dataRecord['source'], 1);
// Check the client limits, if user is not the admin // Check the client limits, if user is not the admin
if($_SESSION["s"]["user"]["typ"] != 'admin') { // if user is not admin if($_SESSION["s"]["user"]["typ"] != 'admin') { // if user is not admin
// Get the limits of the client // Get the limits of the client
......
...@@ -45,19 +45,19 @@ class cronjob_letsencrypt extends cronjob { ...@@ -45,19 +45,19 @@ class cronjob_letsencrypt extends cronjob {
$version = $matches[2]; $version = $matches[2];
if(($type != 'letsencrypt' && $type != 'certbot') || version_compare($version, '0.7.0', '<')) { if(($type != 'letsencrypt' && $type != 'certbot') || version_compare($version, '0.7.0', '<')) {
exec($letsencrypt . ' -n renew'); exec($letsencrypt . ' -n renew');
$app->services->restartServiceDelayed('httpd', 'reload'); $app->services->restartServiceDelayed('httpd', 'force-reload');
} else { } else {
$marker_file = '/usr/local/ispconfig/server/le.restart'; $marker_file = '/usr/local/ispconfig/server/le.restart';
$cmd = "echo '1' > " . $marker_file; $cmd = "echo '1' > " . $marker_file;
exec($letsencrypt . ' -n renew --post-hook ' . escapeshellarg($cmd)); exec($letsencrypt . ' -n renew --post-hook ' . escapeshellarg($cmd));
if(file_exists($marker_file) && trim(file_get_contents($marker_file)) == '1') { if(file_exists($marker_file) && trim(file_get_contents($marker_file)) == '1') {
unlink($marker_file); unlink($marker_file);
$app->services->restartServiceDelayed('httpd', 'reload'); $app->services->restartServiceDelayed('httpd', 'force-reload');
} }
} }
} else { } else {
exec($letsencrypt . ' -n renew'); exec($letsencrypt . ' -n renew');
$app->services->restartServiceDelayed('httpd', 'reload'); $app->services->restartServiceDelayed('httpd', 'force-reload');
} }
} }
......
...@@ -213,6 +213,8 @@ class web_module { ...@@ -213,6 +213,8 @@ class web_module {
$retval = array('output' => '', 'retval' => 0); $retval = array('output' => '', 'retval' => 0);
if($action == 'restart') { if($action == 'restart') {
$cmd = $app->system->getinitcommand($daemon, 'restart'); $cmd = $app->system->getinitcommand($daemon, 'restart');
} elseif($action == 'force-reload') {
$cmd = $app->system->getinitcommand($daemon, 'force-reload');
} else { } else {
$cmd = $app->system->getinitcommand($daemon, 'reload'); $cmd = $app->system->getinitcommand($daemon, 'reload');
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment