Skip to content

Commit

Permalink
Add geoipupdate_retry_for & geoipupdate_parallelism variables
Browse files Browse the repository at this point in the history
  • Loading branch information
boutetnico committed Nov 19, 2024
1 parent e32c756 commit 999a5a4
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ Role Variables
| geoipupdate_proxy_user_password | no | | string | |
| geoipupdate_preserve_file_times | yes | `0` | int | |
| geoipupdate_lock_file | yes | `DATADIR/.geoipupdate.lock` | string | |
| geoipupdate_retry_for | yes | `5m` | string | |
| geoipupdate_parallelism | yes | `1` | int | |
| geoipupdate_cron_state | yes | `present` | string | |
| geoipupdate_cron_user | yes | `root` | string | |
| geoipupdate_cron_special_time | yes | `weekly` | string | |
Expand Down
4 changes: 4 additions & 0 deletions defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,10 @@ geoipupdate_preserve_file_times: 0

geoipupdate_lock_file: "{{ geoipupdate_database_directory }}/.geoipupdate.lock"

geoipupdate_retry_for: "5m"

geoipupdate_parallelism: 1

geoipupdate_dependencies:
- cron

Expand Down
11 changes: 11 additions & 0 deletions templates/GeoIP.conf.j2
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,14 @@ PreserveFileTimes {{ geoipupdate_preserve_file_times }}
# Note: Once created, this lockfile is not removed from the filesystem.
# Defaults to ".geoipupdate.lock" under the DatabaseDirectory.
LockFile {{ geoipupdate_lock_file }}

# The amount of time to retry for when errors during HTTP transactions are
# encountered. It can be specified as a (possibly fractional) decimal number
# followed by a unit suffix. Valid time units are "ns", "us" (or "µs"), "ms",
# "s", "m", "h".
# Defaults to "5m" (5 minutes).
RetryFor {{ geoipupdate_retry_for }}

# The number of parallel database downloads.
# Defaults to "1".
Parallelism {{ geoipupdate_parallelism }}

0 comments on commit 999a5a4

Please sign in to comment.