From 22c226e64c988ebe2cddccd8eba0320e51eeeea4 Mon Sep 17 00:00:00 2001 From: fengtan Date: Mon, 4 Nov 2019 15:55:29 -0500 Subject: [PATCH] Expose sendmail_path as environment variable. --- 7.0/README.md | 3 +++ 7.0/root/opt/app-root/etc/php.ini.template | 2 +- 7.0/s2i/bin/run | 1 + 7.1/README.md | 3 +++ 7.1/s2i/bin/run | 1 + 7.2/README.md | 3 +++ 7.2/root/opt/app-root/etc/php.ini.template | 2 +- 7.2/s2i/bin/run | 1 + 8 files changed, 14 insertions(+), 2 deletions(-) diff --git a/7.0/README.md b/7.0/README.md index e56f1d0d3..99ccd968a 100644 --- a/7.0/README.md +++ b/7.0/README.md @@ -75,6 +75,9 @@ The following environment variables set their equivalent property value in the p * **PHP_MEMORY_LIMIT** * Memory Limit * Default: 128M +* **SENDMAIL_PATH** + * Where the sendmail program can be found + * Default: /usr/sbin/sendmail -t -i * **SESSION_NAME** * Name of the session * Default: PHPSESSID diff --git a/7.0/root/opt/app-root/etc/php.ini.template b/7.0/root/opt/app-root/etc/php.ini.template index 79d983c33..ef72a2e12 100644 --- a/7.0/root/opt/app-root/etc/php.ini.template +++ b/7.0/root/opt/app-root/etc/php.ini.template @@ -973,7 +973,7 @@ pdo_mysql.default_socket= [mail function] ; For Unix only. You may supply arguments as well (default: "sendmail -t -i"). ; http://php.net/sendmail-path -sendmail_path = /usr/sbin/sendmail -t -i +sendmail_path = ${SENDMAIL_PATH} ; Force the addition of the specified parameters to be passed as extra parameters ; to the sendmail binary. These parameters will always replace the value of diff --git a/7.0/s2i/bin/run b/7.0/s2i/bin/run index f18a684a8..d48f14606 100755 --- a/7.0/s2i/bin/run +++ b/7.0/s2i/bin/run @@ -14,6 +14,7 @@ export TRACK_ERRORS=${TRACK_ERRORS:-OFF} export HTML_ERRORS=${HTML_ERRORS:-ON} export INCLUDE_PATH=${INCLUDE_PATH:-.:/opt/app-root/src:${PHP_DEFAULT_INCLUDE_PATH}} export PHP_MEMORY_LIMIT=${PHP_MEMORY_LIMIT:-128M} +export SENDMAIL_PATH=${SENDMAIL_PATH:/usr/sbin/sendmail -t -i} export SESSION_NAME=${SESSION_NAME:-PHPSESSID} export SESSION_HANDLER=${SESSION_HANDLER:-files} export SESSION_PATH=${SESSION_PATH:-/tmp/sessions} diff --git a/7.1/README.md b/7.1/README.md index 3863177bd..4caa08cda 100644 --- a/7.1/README.md +++ b/7.1/README.md @@ -75,6 +75,9 @@ The following environment variables set their equivalent property value in the p * **PHP_MEMORY_LIMIT** * Memory Limit * Default: 128M +* **SENDMAIL_PATH** + * Where the sendmail program can be found + * Default: /usr/sbin/sendmail -t -i * **SESSION_NAME** * Name of the session * Default: PHPSESSID diff --git a/7.1/s2i/bin/run b/7.1/s2i/bin/run index 0bd3128e6..91e6a1391 100755 --- a/7.1/s2i/bin/run +++ b/7.1/s2i/bin/run @@ -14,6 +14,7 @@ export TRACK_ERRORS=${TRACK_ERRORS:-OFF} export HTML_ERRORS=${HTML_ERRORS:-ON} export INCLUDE_PATH=${INCLUDE_PATH:-.:/opt/app-root/src:${PHP_DEFAULT_INCLUDE_PATH}} export PHP_MEMORY_LIMIT=${PHP_MEMORY_LIMIT:-128M} +export SENDMAIL_PATH=${SENDMAIL_PATH:/usr/sbin/sendmail -t -i} export SESSION_NAME=${SESSION_NAME:-PHPSESSID} export SESSION_HANDLER=${SESSION_HANDLER:-files} export SESSION_PATH=${SESSION_PATH:-/tmp/sessions} diff --git a/7.2/README.md b/7.2/README.md index 095545761..9f1a69154 100644 --- a/7.2/README.md +++ b/7.2/README.md @@ -76,6 +76,9 @@ The following environment variables set their equivalent property value in the p * **PHP_MEMORY_LIMIT** * Memory Limit * Default: 128M +* **SENDMAIL_PATH** + * Where the sendmail program can be found + * Default: /usr/sbin/sendmail -t -i * **SESSION_NAME** * Name of the session * Default: PHPSESSID diff --git a/7.2/root/opt/app-root/etc/php.ini.template b/7.2/root/opt/app-root/etc/php.ini.template index 6b4388a41..0e1c2c5e0 100644 --- a/7.2/root/opt/app-root/etc/php.ini.template +++ b/7.2/root/opt/app-root/etc/php.ini.template @@ -973,7 +973,7 @@ pdo_mysql.default_socket= [mail function] ; For Unix only. You may supply arguments as well (default: "sendmail -t -i"). ; http://php.net/sendmail-path -sendmail_path = /usr/sbin/sendmail -t -i +sendmail_path = ${SENDMAIL_PATH} ; Force the addition of the specified parameters to be passed as extra parameters ; to the sendmail binary. These parameters will always replace the value of diff --git a/7.2/s2i/bin/run b/7.2/s2i/bin/run index 0bd3128e6..91e6a1391 100755 --- a/7.2/s2i/bin/run +++ b/7.2/s2i/bin/run @@ -14,6 +14,7 @@ export TRACK_ERRORS=${TRACK_ERRORS:-OFF} export HTML_ERRORS=${HTML_ERRORS:-ON} export INCLUDE_PATH=${INCLUDE_PATH:-.:/opt/app-root/src:${PHP_DEFAULT_INCLUDE_PATH}} export PHP_MEMORY_LIMIT=${PHP_MEMORY_LIMIT:-128M} +export SENDMAIL_PATH=${SENDMAIL_PATH:/usr/sbin/sendmail -t -i} export SESSION_NAME=${SESSION_NAME:-PHPSESSID} export SESSION_HANDLER=${SESSION_HANDLER:-files} export SESSION_PATH=${SESSION_PATH:-/tmp/sessions}