Merge pull request #707 from J0WI/redis-session

Add Redis session handler
This commit is contained in:
J0WI 2019-04-27 15:43:06 +02:00 committed by GitHub
commit da36b3afe6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
10 changed files with 90 additions and 0 deletions

View File

@ -20,6 +20,15 @@ run_as() {
} }
if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then
if [ -n "${REDIS_HOST+x}" ]; then
echo "Configuring Redis as session handler"
{
echo 'session.save_handler = redis'
echo "session.save_path = \"tcp://${REDIS_HOST}:${REDIS_HOST_PORT:=6379}\""
} > /usr/local/etc/php/conf.d/redis-session.ini
fi
installed_version="0.0.0.0" installed_version="0.0.0.0"
if [ -f /var/www/html/version.php ]; then if [ -f /var/www/html/version.php ]; then
# shellcheck disable=SC2016 # shellcheck disable=SC2016

View File

@ -20,6 +20,15 @@ run_as() {
} }
if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then
if [ -n "${REDIS_HOST+x}" ]; then
echo "Configuring Redis as session handler"
{
echo 'session.save_handler = redis'
echo "session.save_path = \"tcp://${REDIS_HOST}:${REDIS_HOST_PORT:=6379}\""
} > /usr/local/etc/php/conf.d/redis-session.ini
fi
installed_version="0.0.0.0" installed_version="0.0.0.0"
if [ -f /var/www/html/version.php ]; then if [ -f /var/www/html/version.php ]; then
# shellcheck disable=SC2016 # shellcheck disable=SC2016

View File

@ -20,6 +20,15 @@ run_as() {
} }
if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then
if [ -n "${REDIS_HOST+x}" ]; then
echo "Configuring Redis as session handler"
{
echo 'session.save_handler = redis'
echo "session.save_path = \"tcp://${REDIS_HOST}:${REDIS_HOST_PORT:=6379}\""
} > /usr/local/etc/php/conf.d/redis-session.ini
fi
installed_version="0.0.0.0" installed_version="0.0.0.0"
if [ -f /var/www/html/version.php ]; then if [ -f /var/www/html/version.php ]; then
# shellcheck disable=SC2016 # shellcheck disable=SC2016

View File

@ -20,6 +20,15 @@ run_as() {
} }
if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then
if [ -n "${REDIS_HOST+x}" ]; then
echo "Configuring Redis as session handler"
{
echo 'session.save_handler = redis'
echo "session.save_path = \"tcp://${REDIS_HOST}:${REDIS_HOST_PORT:=6379}\""
} > /usr/local/etc/php/conf.d/redis-session.ini
fi
installed_version="0.0.0.0" installed_version="0.0.0.0"
if [ -f /var/www/html/version.php ]; then if [ -f /var/www/html/version.php ]; then
# shellcheck disable=SC2016 # shellcheck disable=SC2016

View File

@ -20,6 +20,15 @@ run_as() {
} }
if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then
if [ -n "${REDIS_HOST+x}" ]; then
echo "Configuring Redis as session handler"
{
echo 'session.save_handler = redis'
echo "session.save_path = \"tcp://${REDIS_HOST}:${REDIS_HOST_PORT:=6379}\""
} > /usr/local/etc/php/conf.d/redis-session.ini
fi
installed_version="0.0.0.0" installed_version="0.0.0.0"
if [ -f /var/www/html/version.php ]; then if [ -f /var/www/html/version.php ]; then
# shellcheck disable=SC2016 # shellcheck disable=SC2016

View File

@ -20,6 +20,15 @@ run_as() {
} }
if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then
if [ -n "${REDIS_HOST+x}" ]; then
echo "Configuring Redis as session handler"
{
echo 'session.save_handler = redis'
echo "session.save_path = \"tcp://${REDIS_HOST}:${REDIS_HOST_PORT:=6379}\""
} > /usr/local/etc/php/conf.d/redis-session.ini
fi
installed_version="0.0.0.0" installed_version="0.0.0.0"
if [ -f /var/www/html/version.php ]; then if [ -f /var/www/html/version.php ]; then
# shellcheck disable=SC2016 # shellcheck disable=SC2016

View File

@ -20,6 +20,15 @@ run_as() {
} }
if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then
if [ -n "${REDIS_HOST+x}" ]; then
echo "Configuring Redis as session handler"
{
echo 'session.save_handler = redis'
echo "session.save_path = \"tcp://${REDIS_HOST}:${REDIS_HOST_PORT:=6379}\""
} > /usr/local/etc/php/conf.d/redis-session.ini
fi
installed_version="0.0.0.0" installed_version="0.0.0.0"
if [ -f /var/www/html/version.php ]; then if [ -f /var/www/html/version.php ]; then
# shellcheck disable=SC2016 # shellcheck disable=SC2016

View File

@ -20,6 +20,15 @@ run_as() {
} }
if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then
if [ -n "${REDIS_HOST+x}" ]; then
echo "Configuring Redis as session handler"
{
echo 'session.save_handler = redis'
echo "session.save_path = \"tcp://${REDIS_HOST}:${REDIS_HOST_PORT:=6379}\""
} > /usr/local/etc/php/conf.d/redis-session.ini
fi
installed_version="0.0.0.0" installed_version="0.0.0.0"
if [ -f /var/www/html/version.php ]; then if [ -f /var/www/html/version.php ]; then
# shellcheck disable=SC2016 # shellcheck disable=SC2016

View File

@ -20,6 +20,15 @@ run_as() {
} }
if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then
if [ -n "${REDIS_HOST+x}" ]; then
echo "Configuring Redis as session handler"
{
echo 'session.save_handler = redis'
echo "session.save_path = \"tcp://${REDIS_HOST}:${REDIS_HOST_PORT:=6379}\""
} > /usr/local/etc/php/conf.d/redis-session.ini
fi
installed_version="0.0.0.0" installed_version="0.0.0.0"
if [ -f /var/www/html/version.php ]; then if [ -f /var/www/html/version.php ]; then
# shellcheck disable=SC2016 # shellcheck disable=SC2016

View File

@ -20,6 +20,15 @@ run_as() {
} }
if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UPDATE:-0}" -eq 1 ]; then
if [ -n "${REDIS_HOST+x}" ]; then
echo "Configuring Redis as session handler"
{
echo 'session.save_handler = redis'
echo "session.save_path = \"tcp://${REDIS_HOST}:${REDIS_HOST_PORT:=6379}\""
} > /usr/local/etc/php/conf.d/redis-session.ini
fi
installed_version="0.0.0.0" installed_version="0.0.0.0"
if [ -f /var/www/html/version.php ]; then if [ -f /var/www/html/version.php ]; then
# shellcheck disable=SC2016 # shellcheck disable=SC2016