From 36331a6a9c7aef8e7d49fd5d9d1ffcc37169e215 Mon Sep 17 00:00:00 2001 From: Stefan Schantl Date: Wed, 10 Jun 2020 21:24:58 +0200 Subject: [PATCH] update-location-database: Automatically export database after update. Signed-off-by: Stefan Schantl --- src/scripts/update-location-database | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/scripts/update-location-database b/src/scripts/update-location-database index a329c4cd46..d830286cec 100644 --- a/src/scripts/update-location-database +++ b/src/scripts/update-location-database @@ -39,8 +39,11 @@ if [[ $UPSTREAM_PROXY ]]; then fi # Get the latest location database from server. -if /usr/bin/location-downloader update; then +if /usr/bin/location update; then + # Call location and export all countries in xt_geoip compatible format. + if /usr/bin/location export --directory=/usr/share/xt_geoip --family=ipv4 --format=xt_geoip; then - # Call initscript to reload the firewall. - /etc/init.d/firewall reload + # Call initscript to reload the firewall. + /etc/init.d/firewall reload + fi fi -- 2.39.5