]> git.ipfire.org Git - thirdparty/xtables-addons.git/commitdiff
geoip: add -s option to xt_geoip_build
authorJan Engelhardt <jengelh@inai.de>
Tue, 12 May 2020 20:49:37 +0000 (22:49 +0200)
committerJan Engelhardt <jengelh@inai.de>
Tue, 12 May 2020 20:49:37 +0000 (22:49 +0200)
geoip/xt_geoip_build
geoip/xt_geoip_build.1

index 750bf9835424d5bad6c2ebdbb90b845e52767b7d..7bafa5fbca9ca93c1563c5b8735e95e757812b14 100755 (executable)
@@ -24,6 +24,7 @@ my $target_dir = ".";
 &GetOptions(
        "D=s" => \$target_dir,
        "i=s" => \$input_file,
+       "s" => sub { $target_dir = "/usr/share/xt_geoip"; },
 );
 
 if (!-d $target_dir) {
index ac3e6d38692b1e7ea202af8b05575a502f61acd6..598177f9a8706199782f45f09483474bc7683788 100644 (file)
@@ -27,11 +27,15 @@ Specifies the target directory into which the files are to be put. Defaults to "
 \fB\-i\fP \fIinput_file\fP
 Specifies the source location of the DBIP CSV file. Defaults to
 "dbip-country-lite.csv". Use "-" to read from stdin.
+.TP
+\fB\-s\fP
+"System mode". Equivalent to \fB\-D /usr/share/xt_geoip\fP.
 .SH Application
 .PP
-Shell commands to build the databases and put them to where they are expected:
+Shell commands to build the databases and put them to where they are expected
+(usually run as root):
 .PP
-xt_geoip_build \-D /usr/share/xt_geoip
+xt_geoip_build \-s
 .SH See also
 .PP
 xt_geoip_dl(1)