mirror of
https://abf.rosa.ru/djam/php7.git
synced 2025-02-22 22:32:48 +00:00
11 lines
257 B
Bash
11 lines
257 B
Bash
#!/bin/bash -e
|
|
|
|
max=1440
|
|
|
|
cur=$(sed -n -e 's/^[[:space:]]*session.gc_maxlifetime[[:space:]]*=[[:space:]]*\([0-9]\+\).*$/\1/p' /etc/php.d/*_session.ini 2>/dev/null || true);
|
|
[ -z "$cur" ] && cur=0
|
|
[ "$cur" -gt "$max" ] && max=$cur
|
|
|
|
echo $(($max/60))
|
|
|
|
exit 0
|