Parcourir la source

Rworked mail-wrapper and added HESTIA_VMD var.

Raphael Schneeberger il y a 7 ans
Parent
commit
3462244977
2 fichiers modifiés avec 6 ajouts et 5 suppressions
  1. 5 5
      web/inc/mail-wrapper.php
  2. 1 0
      web/inc/main.php

+ 5 - 5
web/inc/mail-wrapper.php

@@ -1,4 +1,4 @@
-#!/usr/local/vesta/php/bin/php
+#!/usr/local/hestia/php/bin/php
 <?php
 error_reporting(NULL);
 if (empty($argv[1])) {
@@ -15,20 +15,20 @@ if ((!empty($argv[4])) && ($argv[4] == 'no')) {
 
 define('NO_AUTH_REQUIRED',true);
 
-include("/usr/local/vesta/web/inc/main.php");
+include("/usr/local/hestia/web/inc/main.php");
 
 // Set system language
-exec (VESTA_CMD . "v-list-sys-config json", $output, $return_var);
+exec (HESTIA_CMD . "v-list-sys-config json", $output, $return_var);
 $data = json_decode(implode('', $output), true);
 if (!empty( $data['config']['LANGUAGE'])) {
     $_SESSION['language'] = $data['config']['LANGUAGE'];
 } else {
     $_SESSION['language'] = 'en';
 }
-require_once('/usr/local/vesta/web/inc/i18n/'.$_SESSION['language'].'.php');
+require_once('/usr/local/hestia/web/inc/i18n/'.$_SESSION['language'].'.php');
 
 // Define vars
-$from = 'Vesta Control Panel <vesta@'.gethostname().'>';
+$from = 'Hestia Control Panel <hestia@'.gethostname().'>';
 $to = $argv[3]."\n";
 $subject = $argv[2]."\n";
 $mailtext = file_get_contents("php://stdin");

+ 1 - 0
web/inc/main.php

@@ -3,6 +3,7 @@
 session_start();
 
 define('VESTA_CMD', '/usr/bin/sudo /usr/local/hestia/bin/');
+define('HESTIA_CMD', '/usr/bin/sudo /usr/local/hestia/bin/');
 define('JS_LATEST_UPDATE', '1491697868');
 
 $i = 0;