Add deprecation note for ENABLE_PERIODIC_VISIT_LOCATE env var

This commit is contained in:
Alejandro Celaya 2023-05-23 10:55:49 +02:00
parent 3352bcd186
commit 882d64ae11

View File

@ -13,6 +13,7 @@ fi
php vendor/bin/shlink-installer init ${flags}
# Periodically run visit:locate every hour, if ENABLE_PERIODIC_VISIT_LOCATE=true was provided and running as root
# ENABLE_PERIODIC_VISIT_LOCATE is deprecated. Remove cron support in Shlink 4.0.0
if [ "${ENABLE_PERIODIC_VISIT_LOCATE}" = "true" ] && [ "${SHLINK_USER_ID}" = "root" ]; then
echo "Configuring periodic visit location..."
echo "0 * * * * php /etc/shlink/bin/cli visit:locate -q" > /etc/crontabs/root