【问题标题】:"sendmail_path" setup using ".user.ini" files is failed (php-fpm)使用“.user.ini”文件的“sendmail_path”设置失败(php-fpm)
【发布时间】:2019-11-07 13:32:46
【问题描述】:

我使用 PHP 7.3:

PHP Version 7.3.11-1+ubuntu18.04.1+deb.sury.org+1
Server API  FPM/FastCGI

而且我需要为不同的虚拟主机(应用程序)设置不同的 sendmail 配置。

我尝试使用.user.ini文件配置PHP参数:

sendmail_from="user@domain.com"
sendmail_path="/usr/bin/agent -c profile1"

第一个参数被覆盖,但第二个没有:

如果我使用 PHP-FPM,如何为不同的虚拟主机/应用程序配置不同的 sendmail_path 参数?

【问题讨论】:

    标签: php ini fpm


    【解决方案1】:

    sendmail_path 是 PHP_INI_SYSTEM 类设置,在 FPM 池配置中是 php_admin_value[]
    sendmail_from 是一个标准的 PHP_INI_ALL 选项。

    因此,您不能基于 .user.ini / 目录覆盖 sendmail 二进制设置,也不能根据 ini_set() 覆盖。

    【讨论】:

      猜你喜欢
      • 2020-03-09
      • 1970-01-01
      • 1970-01-01
      • 2016-10-25
      • 2021-08-10
      • 2014-09-06
      • 1970-01-01
      • 2015-11-17
      • 2012-01-23
      相关资源
      最近更新 更多