Make the download of geoip data files conditional
This commit is contained in:
parent
1bba0c7899
commit
15c901ed68
2 changed files with 27 additions and 16 deletions
|
|
@ -19,6 +19,10 @@ func init() {
|
|||
return err
|
||||
}
|
||||
|
||||
if err = ctx.MaybeDownloadDataFiles(); err != nil {
|
||||
log.WithError(err).Error("failed to download data files")
|
||||
}
|
||||
|
||||
geoipPath := utils.GeoIPDir(ctx.Home)
|
||||
if *shouldUpdate {
|
||||
utils.DownloadGeoIPDatabaseFiles(geoipPath)
|
||||
|
|
|
|||
Loading…
Reference in a new issue